I have created a module that allows your pages to embargo and expire when you choose.
Available at http://www.silverstripe.com/modules.
This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.
Please use forum.silverstripe.org for any new questions
(announcement).
The forum archive will stick around, but will be read only.
You can also use our Slack channel
or StackOverflow to ask for help.
Check out our community overview for more options to contribute.
I have created a module that allows your pages to embargo and expire when you choose.
Available at http://www.silverstripe.com/modules.
Hi Simon
I was anxious to check it out, cool module! My compliment!
Would be very cool if the embargo/expire feature is also available for the other modules like blog entry, e-commerce, gallery, etc.
Have a nice day
Mario
The only way I can think of to do this would be to subclass each of the page types.
Will get on to it.
Hi Simon
Thanks for feedback.
What do you think to realize it as widget for the other modules?
Cheerio
Mario
As far as I'm aware, that wont be possible, as I use the can() method to hide the links, and I don't think there's a way to override that on a page without subclassing the page type.
Here some cool additions for recurring times:
Can you add the ability so you can specify a page to only show on certain days of the week?
For example: If I wanted a page to show only on Mon, Wed, and Friday and if I dont specify a time its from midnight-midnight be default or something.
Also can you have it so that I can show a page at a recurring time like: everyday or (x)day at 5pm - 7am? or whatever times I choose?
This way someone could show a special every Friday starting at noon if they wanted to. Sort of a "happy hour" if-you-will.
Thanks!
Buddy
Once my patch gets confirmed, I'll release a version that gives every page (that doesn't override can(), without calling parent::can() as well) the ability to Embargo/expiry
Now that Matt's added this to SVN (here), you can see my progress.
There is currently two separate ways for embargo/expiry to be applied. One requires a core patch, and then adds it to every page. The other doesn't require a patch, but is only one page type.
Buddyq, I'll get onto your ideas now (: