Don’t be that site that shows last year’s copyright


I’m in the market for a new job in the Washington, D.C. metro area – I provide comprehensive web content management and strategy – and I have noticed something throughout my search:

Many web sites have a copyright date of 2016.

It’s late March. March 2017.

This suggests that web managers, developers, etc. are still hard-coding their copyrights instead of just letting their CMS display the current year.

Why?

Thankfully, this oversight is completely avoidable. The site, updateyourfooter.com has solutions for WordPress/PHP and JavaScript which I have repeat here. I have included a few other content management systems as well.

Javascript

I’d rather do it from the CMS, but this a simple alternative to getting the current year in the copyright or anywhere else. We used this at GannettDigital long ago.

<script type="text/javascript"> document.write(new Date().getFullYear()); </script>

WordPress/PHP

In WordPress, add this line of code after the ©

<?php echo date("Y"); ?>

If you are not sure where the copyright appears, check functions.php first.

Drupal

There are a few ways, covered here: Auto update to the current year in the copyright footer.

Ektron

I don’t have firsthand experience with Ektron, but here’s what I found when I searched for “add dynamic copyright to Ektron.”

That’s all there is to it, do it once and then never again.

Happy New Year!

Leave A Reply