This is an example of how a limited time offer would work in conjunction with content in a collapse-o-matic expand element.
This demo uses T(-) Countdown Control with a cookie that tracks when the offer expires for each unique visitor. Once the countdown reaches zero, T(-) Countdown Events will remove any special offer items.
For this demo, we’ll set the special timer for just two minutes. The offer will then be removed for 24 hours, and then after the 24 hours are past, the offer will reset.
this is where the details of the special are presented
This is a test of the new T(-) Opening Hours add-on plugin for T(-) Countdown Control.
It will allow a countdown schedule to be defined by referencing a weekly opening schedule.
Normally a countdown groups the units of time (weeks, days, hours, minutes and seconds) into a single countdown unit. But what if you wanted to break out these units and have them displayed on different parts of the page?
Step One. We will need to add a new attribute that tells the countdown NOT to display any of the digits. This way all the countdown scripts and details are still loaded, but the countdown is not displayed. Something like:
[tminus cid="123" hidden="true" style="cloud-city"/]
Step Two. A new shortcode will need to be created for displaying the time unit. We will need to know the countdown id (cid) the time unit to be displayed, and the style to be used, if other than the default style set up on the plugin settings. If a custom style is used it must be defined in both the countdown and the units like so:
[tminus_digit cid="123" unit="hours" style="cloud-city"/]
The final set will be to modify the countdown script to locate the time units, even if they are not wrapped in a countdown dashboard.
Let’s get started.
Here is a hidden countdown:
Now we add all the digits, starting with weeks:
Using the new [this year] and [this_easter] shortcodes introduced with T(-) Countdown version 1.8.0, it’s easy to calculate holidays such as labor day like so:
Launch Strtotime: september [this_year] first monday
As of version 1.8.2, using these shortcodes will automatically recalculate for next year’s date after the holiday has past. Holidays should be set as recurring ‘Yearly’ and they will automatically be rescheduled for next year.
Other Holidays can be calculated in the same manner:
- New Years: first day of january [this_year]
- Martin Luther King, Jr. Day: january [this_year] third monday
- President’s Day: february [this_year] third monday
- Easter: [this_easter]
- Ascension Day: [this_easter] + 40 days
- Pentecost: [this_easter] + 50 days
- Memorial Day: last monday of may
- Independence Day: july 4 [this_year]
- Labor Day: september [this_year] first monday
- Columbus Day: october [this_year] second monday
- Veteran’s Day: november 11 [this_year]
- Thanksgiving Day: november [this_year] fourth thursday
- Christmas Day: december 25 [this_year]
The target date is: Thu, 25th May, 2017
Eight Days before Thanksgiving
november [this_year] fourth thursday + 14 hours 30 minutes – 8 days
The target date is: Wed, 15th November, 2017
Test of a faster redirect when a countdown is already expired.
T(-) Countdown Control already has the ability to store a visitors calculated launch time to a cookie. As of version 1.7.7 we have added integration of a new add-on plugin T(-) Countdown Tracking. This new premium plugin adds the ability to save the visitors IP address in the database. More details to follow.
Test using Schedule:
Counting Down to Thu, 27th April, 2017
Test using basic shortcode:
[tminus t="+2 minutes" id="test_counter" track_id="2571" /]
This is a test of the cloud-city style for T(-) Countdown to adjust the spacing issue on lower viewports.
This countdown should launch Monday-Friday at 09:00 and 12:00 and certainly NOT on the weekend.
Launches on: Thu 2017-04-27 09:00:00