Since we are at the start of a new year, many people will be updating their website footers to correct the current year in their copyright notice. Here is a quick tip for those of you using PHP who wish to update the year automatically. You can use this tip with WordPress since it is PHP-powered.
Use this php code below in your footer to print a copyright notice for the current year.
This website © <?php echo date("Y"); ?>
This will print out something like this:
This website © 2009
A lot of people (myself included) like to add the first year that a page was published to their copyright notice. You can hard code the starting year and get PHP to dynamically update the current year. Modify this code to suit your needs:
This website © 2005 - <?php echo date("Y"); ?>
Your copyright footer will now look something like this:
This website © 2005 - 2009
Hope you find this tip useful.
Smack-dab what I was lonoikg for-ty!