I am creating a page type for the GHOP that allows you to specify what times the page can be viewed for (see [url]http://code.google.com/p/google-highly-open-participation-silverstripe/issues/detail?id=105[/url] for more information).
I currently have the page become unpublished when it expires, however I need a way to either publish a page or change ShowInMenus without calling the page, as it shouldn't be able to be called.
Are you talking about
a) turning an embargoed page into one that is "normal"?, or
b) turning a "normal" page into an expired one?
If (a), the usability needs a little thought. I don't think we want to turn a page that is merely on the draft site into a published page. The user would need to click 'save and publish' because the user may wish to keep the page on the draft site while editing it etc. Maybe when you clicked save and publish, the message that pops back would be "Page will be brought online on Monday 23rd January 2008" to reinforce whats going to occur. Behind the scenes its up to you how to manage it, but you need to work out if its better to publish the page and add checks all over the place like "show page if expiry is null or expiry is after now()" OR only bring the page online at the right point "some how", e.g. where you do a 404 check or as an extension of DailyTask that runs on a schedule.
(b) should be easy if visiting a page, but be careful that, lets say you have a website with a top menu of "Home About Contact". If "about" has expired and you visit the homepage you need to hide 'about', without the logic being computationally expensive. (hence a where filter at the SQL level seems good)