› News › Web Development
 › Keep the year in your website footer up to date – How to
   -   6 January, 2020

Keep the year in your website footer up to date – How to

Learn how to always keep the copyright year up to date in your website footer - keeping you from coming back to update it every year!

Place this code within the functions.php file of your child theme:

// Display Current Year Shortcode
 function year_shortcode() {
   $year = date('Y');
   return $year;
 } add_shortcode('year', 'year_shortcode');

Then, where you want to display the current year, place 2020.

CATEGORIES
POPULAR ARTICLES
The importance of consistency to build a solid brand.
The importance of consistency to build a solid brand.

Branding is much more than just a cool logo or a well-placed advertisement. A solid brand is the foundation upon which your corporate culture and future growth is built. Crucial to every business, it tells people that you care about what you deliver, that you live up...

Stop spam in WordPress: How to (Updated for 2020)
Stop spam in WordPress: How to (Updated for 2020)

It converts selected email addresses characters to HTML entities to block spambots. Not all characters in the email address are converted: the selection is random and changes each time the function is called. To use this in your WordPress Content area all...

Create buttons with rounded corners for emails – How to
Create buttons with rounded corners for emails – How to

The other week I had a client who was insistent on having their rounded buttons in their new HTML Mailchimp template. After spending way too long tearing my hair out trying to get it working in all clients, I stumbled across the below hack. The below code is a simple...

TAGGED WITH

//

We want to hear what you think about this article, or what you would like us to write about next! Submit a comment below or write to us at hello@studiotwofold.com.au.
Studio Twofold provides creative design services and advice to growing Australian businesses to help them feel confident and kick goals. Learn more about us.

READ THESE NEXT

0 Comments

Submit a Comment

Your email address will not be published. Required fields are marked *

Want to talk?

Our process begins with a conversation about your business and how we can help.