This tutorial explains how to handle converting times to different time zones using the DateTime and DateTimeZone classes.
When writing object oriented PHP code, keeping track of required classes can be a problem. This tutorial explains how to use the autoload function to let PHP handle the dependencies automatically.
Sometimes, you might need to convert an integer representing seconds into a format that is easier to read. These functions can be used to turn a number of seconds into a simple readable format. This can be used for countdown scripts, which is why I also include both a PHP and a JavaScript version.
There are many benefits to writing clean code for any project, no matter how small. The importance of clean code becomes most apparent when you need to find an error, especially a syntax error. In the end, cleaner code means less time reading and more time coding.
This tutorial will explain how to access the Twitter API to fetch a user timeline using raw PHP. This will be a very basic use of the Twitter API, but it should give you a starting point if you need to do something more advanced.
In this tutorial, we will explore the PHP DOMDocument class by generating an entire HTML page without writing a single bit of raw markup. This may not be practical for most applications, but it should give you a good idea of how the basic DOMDocument methods work.
In this tutorial, we will use the PHP DOMDocument class to load and modify an HTML template.
PHP supports MySQL prepared statements using the Mysqli extension via the MySQLi STMT class. They are fairly easy to use once you get used to the differences from writing raw SQL statements. This tutorial will explain how to use prepared statements.
This tutorial will explain how to make an animated add to queue type functionality with jQuery. Since it is hard to explain the results, check out the demo. First, I will show how to create the actual effect, and then how to implement AJAX submission to a back-end script for database storage or some other processing.
When creating a PHP application, it is usually necessary to connect to a database to perform certain tasks. In some cases you only want to open a connection when necessary, but limit it to a single connection. For these situations I use the Singleton Pattern, which is perfect for this.