Display Current Year with Shortcode
Follow the below steps to display the current year with shortcode anywhere in WordPress.
Install ShortcodeHub Plugin Install ShortcodeHub Plugin
NOTE: If you already have installed the ShortcodeHub plugin then skip this step.
- Buy ShortcodeHub and Download the ZIP
- Then, Go to Your WordPress Website
- Plugins > Add New
- Click on the Uploads button
- Select the zip and Click upload
- Then, Click on Activate plugin.
Done. You’ll see the ShortcodeHub plugin dashboard screen.
Top ↑Use Year Shortcode in WordPress Use Year Shortcode in WordPress
Use the shortcode:
[sh_date format='Y']
Below is the output of the above shortcode:
2023 Top ↑Display Current Year With Mixed Text Display Current Year With Mixed Text
Suppose you want to show the text with the current year something as below:
Current year [sh_date format='Y']
Below is the output of the above shortcode:
Current year is 2023
Was this helpful?