Display content twice a year
-
Hi Dave
I have a Gravity Form on a page that needs to display for two regular periods of time every 12 months. As Gravity only allow a single schedule, I will leave the form on constantly and wrap the GF Shortcode with your plugins repeat shortcode, suitably configured.
The time periods are between 1st April and 31st July and subsequently from 1st October and 28/29th February. In between these periods I’ll use the ‘else’ attribute to show a message about when the form will be available.
So far I’ve got the following:
[time-restrict-repeat type=”annually” onmonth=”April” offmonth=”July” ondate=”01″ offdate=”31″ else=”The Form is currently unavailable. It will be available between 1st April and 31st July and subsequently from 1st October and 28/29th February each year.”]
Gravity Form ID X Shortcode Here
[/time-restrict-repeat]
[time-restrict-repeat type=”annually” onmonth=”October” offmonth=”February” ondate=”01″ offdate=”29″ else=”The Form is currently unavailable. It will be available between 1st April and 31st July and subsequently from 1st October and 28/29th February each year.”]
Gravaity Form ID X Shortcode Here
[/time-restrict-repeat]My concerns are;
a) the end of year overlap,
b) the February leap year issue for ‘offdate’ attribute (could be 28th or 29th), and
c) will the ‘else’ text display twice when the date falls outside both active time periods?I’d rather you run your eye over this than wait for it to appear wrong on the live site! Is there a neat way to test such scheduling by ‘tricking’ a webserver or website into thinking it is actually a different date/time? Would love this ability occasionally.
Appreciate your confirmation or tweaks.
- The topic ‘Display content twice a year’ is closed to new replies.