Occasionally I need to add temporary content alerting visitors to something that will cease to be relevant on a certain date. For this I create a Global Content Block and manually add and remove it from the relevant page.
Is there an easy way to schedule a GCB to be removed on a given day e.g. not displayed beyond a certain unix time? A plugin with parameters for the GCB and unix time of start and end times maybe?
Simple GCB Scheduling Plugin? [solved]
Simple GCB Scheduling Plugin? [solved]
Last edited by Jonny on Wed Jan 23, 2013 4:50 pm, edited 1 time in total.
-
- Support Guru
- Posts: 8169
- Joined: Tue Oct 19, 2004 6:44 pm
Re: Simple GCB Scheduling Plugin?
something like this should work:
Code: Select all
{if $smarty.now < strtotime('February 1, 2013')}
DISPLAY SOME CONTENT
{/if}
Follow me on twitter
Please post system information from "Extensions >> System Information" (there is a bbcode option) on all posts asking for assistance.
--------------------
If you can't bother explaining your problem well, you shouldn't expect much in the way of assistance.
Please post system information from "Extensions >> System Information" (there is a bbcode option) on all posts asking for assistance.
--------------------
If you can't bother explaining your problem well, you shouldn't expect much in the way of assistance.
Re: Simple GCB Scheduling Plugin?
That's certainly simple and effective! Thanks very much.