
This plugin provides a shortcode and a set of functions to return the number of days since the most recent past event in your Google Calendar matching specified search terms. The shortcode can also be used to return the number of days until the closest upcoming event matching specified search terms.
[gcal-days search="" type="" id=""]
The shortcode name is gcal-days. It has three attributes, but only one of which is absolutely necessary:
The shortcode outputs a number representing the number of days until a matching event. If no event is found, a -1 will be displayed.
Examples: [gcal-days search="dentist"], [gcal-days type="until" search="vacation" id="[email protected]"]
Links: Plugin Homepage | Plugin Directory Page | Author Homepage
The plugin provides two functions for use in your theme templates, functions.php, or in plugins.
$search (string)
Required. The word or phrase to search for
$calendar_id (string)
Optional. The ID for the Google Calendar. Check the plugin’s settings page for calendar IDs. This argument is only optional if you have defined a default calendar via the plugin’s settings.
An integer value of the number of days since/until the matching event. -1 is returned if no event was found or an error was encountered.
<?php // Days until next dentist appointment
$days_until = gcal_days_until( 'dentist' );
?>
<?php
// Get the days since my last day off
$days_since = gcal_days_since( 'day off' );
// Echo a message using that number
if ( -1 == $days_since ) {
echo "You've never had a day off?! Take one soon!";
} else {
printf( _n( 'Your last day off was %d day ago.', 'Your last day off was $d days ago.', $days_since ), $days_since );
}
?>
Starting from $0 per month.
Rating
Reviewers
No reviews
Tags
Developed By
Scott Reilly
Quick & Easy
Common Ninja has a large selection of powerful Wordpress plugins that are easy to use, fully customizable, mobile-friendly and rich with features — so be sure to check them out!
Testimonial plugins for Wordpress
Contact Form plugins for Wordpress
Maps plugins for Wordpress
Translation plugins for Wordpress
Chat plugins for Wordpress
Slider plugins for Wordpress
Reviews plugins for Wordpress
Contact plugins for Wordpress
Galleries plugins for Wordpress
SEO plugins for Wordpress
Forms plugins for Wordpress
Comments plugins for Wordpress
Backup plugins for Wordpress
Privacy plugins for Wordpress
Optimize plugins for Wordpress
Tabs plugins for Wordpress
Social Sharing plugins for Wordpress
Events Calendar plugins for Wordpress
Comments plugins for Wordpress
Social Feeds plugins for Wordpress
Social Sharing plugins for Wordpress
Portfolio plugins for Wordpress
Video Player plugins for Wordpress
popup plugins for Wordpress
SiteMap plugins for Wordpress
Payment plugins for Wordpress
Coming Soon plugins for Wordpress
Inventory plugins for Wordpress
Testimonials plugins for Wordpress
Portfolio plugins for Wordpress
Membership plugins for Wordpress
Forms plugins for Wordpress
Analytics plugins for Wordpress
Events Calendar plugins for Wordpress
Sliders plugins for Wordpress
Analytics plugins for Wordpress
Reviews plugins for Wordpress
Security plugins for Wordpress
Ads plugins for Wordpress
Music Player plugins for Wordpress
Countdown plugins for Wordpress
Email Marketing plugins for Wordpress
Membership plugins for Wordpress
Ecommerce plugins for Wordpress
Customer Support plugins for Wordpress
Video Player plugins for Wordpress
Tabs plugins for Wordpress
Social Feeds plugins for Wordpress
Common Ninja Apps
Browse our extensive collection of compatible plugins, and easily embed them on any website, blog, online store, e-commerce platform, or site builder.

Show Facebook posts in a live Facebook feed that keeps content fresh, boosts social proof, and helps visitors engage more with your brand.
Show Apple App Store reviews to build trust, strengthen credibility, and help visitors make confident download decisions that support app growth.

Show Vimeo videos in a Vimeo feed that keeps content fresh and helps visitors discover more of your video library.
Use a support form that lets customers submit tickets, saves each request, sends notifications, and helps you manage support more efficiently.
Add an FAQ section to your site to answer common questions, reduce support requests, and give visitors a smoother and more confident user experience.
Use a contact form so visitors can send messages, submit inquiries, and help you collect leads and improve user experience.
Use a scroll progress bar that visually tracks reading on the page, improves navigation, and keeps visitors aware of their position.
Show LinkedIn posts in a live feed that keeps updates current, builds credibility, and helps visitors engage with your brand.
Slide in panel that appears from the top or bottom to highlight offers, capture attention, and guide visitors toward more conversions.

Show Mastodon posts in a live Mastodon feed that keeps content fresh, strengthens your social presence, and helps visitors engage with your updates.
Add charts and graphs to your site to present data clearly, help visitors understand insights faster, and support more confident decision making.
Use wake up notifications to re engage visitors with custom alerts that capture attention, boost interaction, and help increase conversions across your site.
More plugins
The Common Ninja Search Engine platform helps website builders find the best site widgets, apps, plugins, tools, add-ons, and extensions! Compatible with all major website building platforms - big or small - and updated regularly, our Search Engine tool provides you with the business tools your site needs!
