So it’s a new year and many of us need to go through some sort of reorientation in our minds when it comes to what year it is. Lemme brag and say I doubt I’ll be saying or typing 2009 by mistake anywhere. But for web designers one thing that we often forget to do is update the year in the copyright at the bottom of our websites. I’m sure there’s many of my site’s with the wrong year right now and I’m not sure if I have enough time to go through all of them, but one thing I’ve been doing to solve this problem is to dynamically generate the year.

Intsead of just typing © 2010 or © 2004-2010 I replace the year part with <? date(“Y”); ?> (since most of my work these days is in PHP) which uses the PHP date function to echo out the current year. This way I’ll never have to manually update the date on my sites and the date will automatically change every year. :)

HAPPY NEW YEAR EVERYONE!!!

Post a Comment

*
*