/    Sign up×
Community /Pin to ProfileBookmark

Schedule page display

I need to be able to pre-schedule what day(s) specific pages are displayed or when specific links become live. I am using DreamweaverMX for site development. It has been suggested that adding java script to the Dreamweaver html code may automate the scheduling. I have done a little searching of some of the scripts available online, but haven’t found anything that sounds right. Can anybody suggest such a script or something else I might check into?

Thanks.

to post a comment
JavaScript

1 Comments(s)

Copy linkTweet thisAlerts:
@AdamGundryDec 04.2002 — The easiest way to do this is probably to generate the scheduled hyperlinks using JavaScript, something like the following:

[CODE]
var NowDate = new Date();
var ShowDate = new Date(2003,0,1);
if (NowDate.getTime > ShowDate.getTime){
document.write('<a href="time1.html">Can't see this until 1st January 2003</a>');
} else{
document.write('Page not yet available.');
}
[/CODE]


Bear in mind that this will fail for any user without JavaScript support, and it is fairly easy to circumvent if a user wishes to look at a page ahead of schedule.

The date it becomes active is set in the ShowDate variable. You could also express this as Date("January 1, 2003");.

Hope this helps

Adam
×

Success!

Help @sgron spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 5.16,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @AriseFacilitySolutions09,
tipped: article
amount: 1000 SATS,

tipper: @Yussuf4331,
tipped: article
amount: 1000 SATS,

tipper: @darkwebsites540,
tipped: article
amount: 10 SATS,
)...