Happy New Year!! 🎊
Did you remember to update your websites with the new copyright year?
All you need to do is make sure that your copyright statement is within
<p></p> tags so this will be visible (not just within
One important thing to note first… if you didn’t already know, the
getYear() method is deprecated, so you’ll need to use the
Here’s an example of what the code looks like:
And there you have it! Easy enough, right? Now if you add this little snippet to your sites, you won’t have to worry about updates every year! That
<script> will display the current year right next to the
© copyright symbol.
Here’s wishing everyone a happy, healthy and prosperous new year!
Date.prototype.getFullYear() on MDN