1. Hello Guest!

    Thank you for visiting the ClubRunner Community website, you can login using your ClubRunner account information by clicking the login link on the top of every page.
    Dismiss Notice

Auto generate the year for the year in the footer copyright notice

Discussion in 'Website Customization' started by Bob Murray on Jan 2, 2018.

  1. Bob Murray

    By:Bob MurrayJan 2, 2018
    New Community Member

    Jan 2, 2018
    Likes Received:
    Sun City West, AZ, United States
    Hello - I've been using the following code in previous CR themes, WordPress and other website tools. I thought I would share it for anyone who does not want to manually enter the new year their footer.
    <script>document.write(new Date().getFullYear())</script>
    ------ Below is the complete code for the footer ------
    <center><span style="color:rgb(153, 153, 153); font-family:times new roman"><strong>Rotary Club of Sun City West</strong> © 2010 - <script>document.write(new Date().getFullYear()) </script>&nbsp;All rights reserved.</span></center>
    Please note: Do not be alarmed when the new year is not displayed within the widget. However once saved, the footer displays the new year on your website.

    Bob Murray
    David H. and Zach like this.