Page 1 of 1

Dynamic Copyright Footer Text Year

Posted: Tue Aug 30, 2022 8:07 am
by xgis

Copyright years in footer text are usually updated manually. To make them automatically update each year without regenerating the application a simple script can be used.

Two examples below. One shows copyright based on a year range and one on a single year. Simply copy and paste into the footer text field on the HTML > General tab > Footer text

Single Year eg Changes to current year automatically:
&copy;<script>document.write(new Date().getFullYear())</script> Your Company Name. All rights reserved.

Year Range Example:
&copy;2010-<script>document.write(new Date().getFullYear())</script> Your Company Name. All rights reserved.

Just set it and forget it!


Re: Dynamic Copyright Footer Text Year

Posted: Tue Aug 30, 2022 9:17 am
by xgis

To add some extra functionality and have the footer include a URL redirect link to your web page do the following in the Footer Text....

&copy;<script>document.write(new Date().getFullYear())</script> <a href="https://www.yoururl.com" target ="_blank">Your Company Name</a>. All rights reserved.

This opens a new tab in the browser so your database editing application remains unaffected.