How To Add A Dynamic Copyright Year in Divi Footer Bottom Bar

The Divi Bottom Bar, located just below the WordPress footer, is a perfect place for Copyright © 2019 information. If you do not want to add a dynamic year, it is easy enough to just edit the text in the Theme Customizer by editing the Footer->Bottom Bar->Edit Footer Credits field. But every year you have to manually edit that year so that it will reflect the current year. If you don’t do that, your visitors will notice it and feel that it’s an out dated site with no maintenance. So why not create an automatic feature that keeps the year fresh for you – year after year? Just follow the step-by-step guide below and stop worrying about outdated WordPress footers.

Let’s dive in!

The easiest way to use a dynamic year in your Divi Footer copyright section is to use a small Javascript code snippet. Divi makes that super easy. Here’s how:

Navigate to Divi->Theme Options in your dashboard.

Paste the following code under the “Integration” tab in the header code section.

<script>
// Add A Dynamic Year In Divi Footer Copyright
 var beg_year = 2018; // Year site went live
 var this_year = new Date(); // Get current date
 var copyright_text = ' Company Name | All Rights Reserved ';
 var developed_by = '| Made with <span id="icon-love" class="et-pb-icon et-waypoint et_pb_animation_top et-animated"></span> by <a href="https://yourdomain.com" target="_blank">Your Company Name</a>'; // Developer info

 this_year = this_year.getFullYear();
 if(this_year > beg_year) {
 var year = beg_year + ' - ' + this_year;
 } else {
 var year = this_year;
 }
 jQuery(function($){
 $('#footer-info').html('© ' + year + ' ' + copyright_text + ' ' + developed_by );
 });
</script>

Obviously you are going to want to use your domain and text to specialize the output for your needs.

After you have clicked “Save” in the Divi Theme Options panel, return to the front-end of your website, and you will notice that the footer has been updated.

Tawfiqur

I'm a freelance Wordpress Front-end Developer, work from my home office. Mostly do my freelance work on Upwork. I'm a TOP RATED freelancer with over 11K+ Work Hours. Specialize in HTML5, CSS3, SCSS, JavaScript, jQuery, Ajax, ES6, Bootstrap, PHP, MySQL, Wordpress, Woocommorce and Custom Wordpress Theme and Plugin Development

This Post Has 4 Comments

  1. That was really helpful. Thank you 🙂

  2. Worked great except my heart icon is huge. How do I change it?

Leave a Reply

Close Menu