Expire a web page and replace with a new page

B

Bob

Is there a way to have a page (say page1.html) expire on a certain date and
redirect to a new page (say page2.html) after that date? I'd like to keep
the old page1.html for reference but display page2.html after the expiration
date.

Thanks

Bob
 
J

Jon Spivey

Hi Bob,

You'd probably need some server side code. In asp you could do
<%
if date() > [YourExpiryDate] then
response.status="301 Moved Permanently"
response.addheader "Location", "http://you.com/page2.htm"
end if
%>

Don't be tempted to just stick a response.redirect in there as the search
engines will penalise you.
 
A

Andrew Murray

Under Insert > Web Component, then choose Included Content.

Then choose "Page Based on Schedule". This uses the FP server Extensions,
so you might need an alternative as below if you don't use the FPSE on your
server.


Jon Spivey said:
Hi Bob,

You'd probably need some server side code. In asp you could do
<%
if date() > [YourExpiryDate] then
response.status="301 Moved Permanently"
response.addheader "Location", "http://you.com/page2.htm"
end if
%>

Don't be tempted to just stick a response.redirect in there as the search
engines will penalise you.

--
Cheers,
Jon
Microsoft MVP

Bob said:
Is there a way to have a page (say page1.html) expire on a certain date
and
redirect to a new page (say page2.html) after that date? I'd like to keep
the old page1.html for reference but display page2.html after the
expiration
date.

Thanks

Bob
 
K

Kathleen Anderson [MVP - FrontPage]

In order for that to work, you need to open the live web and recalculate the
hyperlinks after the time you've specified.

--

~ Kathleen Anderson
Microsoft MVP - FrontPage
Spider Web Woman Designs
web: http://www.spiderwebwoman.com/resources/


Andrew Murray said:
Under Insert > Web Component, then choose Included Content.

Then choose "Page Based on Schedule". This uses the FP server Extensions,
so you might need an alternative as below if you don't use the FPSE on
your server.


Jon Spivey said:
Hi Bob,

You'd probably need some server side code. In asp you could do
<%
if date() > [YourExpiryDate] then
response.status="301 Moved Permanently"
response.addheader "Location", "http://you.com/page2.htm"
end if
%>

Don't be tempted to just stick a response.redirect in there as the search
engines will penalise you.

--
Cheers,
Jon
Microsoft MVP

Bob said:
Is there a way to have a page (say page1.html) expire on a certain date
and
redirect to a new page (say page2.html) after that date? I'd like to
keep
the old page1.html for reference but display page2.html after the
expiration
date.

Thanks

Bob
 
B

Bob

Thanks for the suggestions. I'm going to try the ASP code for date > then
redirect and see how that goes.

I appreciate you taking the time to answer.


Bob
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top