Allows Site Visitors to display the Day of Week for any Date they enter, via Shortcode or PHP Function.
Formerly: "jonradio Perpetual Calendar"
Display the Day of Week for virtually any Date, from 6500 years in the past to 8000 years in the future. A Shortcode allows you to insert (anywhere on your WordPress site) a Form for your Web Site Visitors so that they can enter a Date and display the Name of the Day of the Week for that Date. Both the Name of the Shortcode, which defaults to
[pcal], and the Format of the Date can be modified from the Admin Settings panel for this plugin. A "Help and Info" button provides Visitors with background and usage details.
Providing your site visitors with a Perpetual Calendar is as easy as installing and activating this Plugin with Add Plugin and inserting the
[pcal] Shortcode in a Page, Post or any other place where Shortcodes are allowed.
Click here for a Live Demo of the Plugin: http://zatzlabs.com/plugins/
This Plugin has been Internationalized ("Translation-Ready"). Both the Admin and User (Site Visitor) views are presently available in either English or Spanish, with a .POT translation file available in the /languages/ directory within the Plugin, for any translators wishing to translate it into other languages, which we would love to include in future versions of the Plugin. Special thanks to Andrew Kurtis of WebHostingHub for the Spanish translation.
Once the plugin is successfully installed and activated, adding the plugin's Shortcode (by default,
[pcal]) to any WordPress Post or Page will insert an HTML
<form> that prompts the user to select a Month, Day, and Year from drop-down lists. Clicking the "Display Day of Week" button will generate a message above the
<form> indicating the full name of the day of the week for the given date. Or an error message for all invalid dates. Clicking the "Help and Info" button will display, right below the Perpetual Calendar, instructions explaining what it is and how to use it.
To reduce the size of the drop-down lists, the Year is entered in three parts: (1) first one or two digits ("century"); (2) second to last digit ("tens"); and (3) last digit. Plugin Settings are provided within the WordPress Admin panels to display current era dates as A.D., CE or solely by the numeric Year; ancient dates are displayed as B.C. or BCE, or are not allowed when current era dates are displayed solely as numbers. A.D./B.C. is the default.
A PHP Function,
jr_weekday, given Day, Month and Year as input parameters, will return the Date and Day of the Week as a formatted message that you can insert anywhere in the PHP code of your site. The Format of the Date in the message can be modified from the Admin Settings panel for this plugin. Like the Shortcode and Admin panels, the language of the message returned by the PHP function is controlled by the 'WPLANG' constant defined in wp-config.php
If Network is turned on in WordPress, Network Activation of the plugin allows both the plugin and shortcode to be called from all WordPress sites within the Network. Alternatively, the plugin can also be activated for individual sites within the Network.
Supported dates range from November 25, 4714 B.C. (1 A.D. when Plugin Settings specify "Do not allow Dates more then 2000 Years in the Past") to December 31, 9999 A.D.; the jr_weekday function accepts years larger than 9999, but it has not been tested for accuracy past the year 9999. Illegal dates, such as February 31 of any year, and the Year Zero (A.D. or B.C.), are detected and an error message is returned in place of the message indicating the weekday.
Multiple uses of the plugin's Shortcode on the same Page are detected: the first works normally, but all others display the Shortcode's Name, surrounded by square brackets, followed by "(duplicate)". Likewise when displaying multiple Posts, with the Shortcode occurring more than once across all the displayed Posts.
This plugin was recently adopted by David Gewirtz and ongoing support and updates will continue. Feel free to visit David's Lab Notes for additional details and to sign up for emailed news updates.
Special thanks to Jon 'jonradio' Pearkins for creating the plugin and making adoption possible.
Requires: 3.0 or higher
Compatible up to: 4.3.1
Last Updated: 2015-9-2
Active Installs: 10+
Got something to say? Need help?