Magento current year on footer

If you ever wonder why some sites have old years (not even the last one) on footer copyright text, for me this comes from a lazy development, since it can be quickly fixed with code, in this case I’m going to show you how to do it in Magento e-commerce platform:

First login to your Magento admin panel and in

System -> Configuration -> Design -> Footer -> Copyright

type:

Copyright ©  Company Name. All Rights Reserved.

Then open the following file to edit code:

/app/design/frontend/[interface]/[theme]/template/page/html/footer.phtml

Lookup for the following section of code:


And replace it with:

<!--?php echo preg_replace('/<YEAR\?-->/', date('Y'), $this-&gt;getCopyright()) ?&gt;

Hope this help someone out there.

See this solutions on Magento forums