Beaver Builder: Automatic Date in Footer
Never want to spend another New Year’s Day updating copyright dates in website footers? Good.
Add this function to your WordPress child theme’s functions.php file:
// Add shortcode to output the year for footer function ci_footer_year_shortcode() { $thedate = date('Y'); return $thedate; } add_shortcode('ci_output_year', 'ci_footer_year_shortcode');
If you’re using Beaver Builder’s default footer, you can then add the new shortcode in place of the year:
// Note: remove the spaces before/after the brackets © [ ci_output_year ] [ wpbb site:title ]. All Rights Reserved.
The same shortcode will work in other themes of course as well… and as the comment says, be sure to remove the spaces before/after the brackets in order for the shortcode to work.
Thank you. Worked like a charm. I’ve been meaning to do that on many sites. I just implemented it on two of them. Thanks!