Forum Moderators: open

Message Too Old, No Replies

Temporarily Redirect All Users

         

almo136

9:31 pm on Jul 29, 2009 (gmt 0)

10+ Year Member



Hi,

I need to make some changes to my site and would like to take it down temporarily.

I'd like it so that averyone who tries to view my site will get redirected to a "we'll be back soon" page. Whats the best way to do this so that no matter what page the user lands on they will get redirected?

Thanks.

lavazza

2:26 am on Jul 30, 2009 (gmt 0)

10+ Year Member



As long as you have full admin rights to your server, you could over-write the 'normal boring 404 - Error' file with a Custom 404 [google.com] that says something (anything!) 'helpful' and/or whatever you have in mind for your "we'll be back soon" page, which could include a clickable link to another site AND/OR an html meta redirect [google.com], which (after a specified number of milliseconds) auto-magically whisks the visitor off to another page/site

almo136

2:43 am on Jul 30, 2009 (gmt 0)

10+ Year Member



Hi,

I actually have customized my 404 page but I don't think I explained myself very well.

My site will still be there but I just want to prevent people from accessing the main content because things are going to be changing/broken for a little while. Instead everyone should be sent to a specific page ie. "we'll be back soon"

Thanks.

lavazza

2:57 am on Jul 30, 2009 (gmt 0)

10+ Year Member



In that case, try implementing htaccess 301 redirects [google.com]

tedster

3:11 am on Jul 30, 2009 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



But since 301 is for a "permanent" redirect, you would be better using a 302 "temporary" redirect. Otherwise you may confuse the search engines -- a lot.

Or even better, return a "503 Service Unavailable" status with a custom error page.

swa66

3:19 am on Jul 30, 2009 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Sounds like a task for mod_rewrite if you still want to have the ability to access the site yourself.