Magicode.org - where experts come together.
Every web site needs a counter. You can implement Google Analytics or some other fully fledged statistics system, but for most sites, that's just overkill. Read on for a simple PHP-based counter that does not rely on database access.
A variable is a means of storing a value, such as a text string or a number. In PHP you do not have to declare your variable, as it's automatically declared when you set it. Since you do not need to declare the variable, you do not have to specify what kind of data it contains either.
If you have a web site or blog, it's important to spread the word, and what's better than a properly designed and updated RSS feed? Here's how to write a PHP script that fetches the last 10 items from your database and writes it to a RSS-file.