Forum Moderators: phranque

Message Too Old, No Replies

[htaccess] Forward everyone but me to bla.html

based on ip..

         

rubenski

11:07 pm on May 10, 2005 (gmt 0)

10+ Year Member



Hi,

I have been able to protect my site from everyone but my own IP with 'deny' and 'allow'. But this results in a 500 error for everyone that visits (but me). I am looking for a way to direct all requests to bla.html, except from my own ip. I need to shut down my site for a few days, because I am changing hosts. While the site is down I want to display a small "we'll be right back" message.

jdMorgan

11:55 pm on May 10, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



The 500 error indicates that your code is incorrect. The normal response to a 'deny' would be a 403-forbidden. Since you didn't post an example of your code, I can't comment further.

Shutting down a site is not usually necessary when changing hosts, except for those sites which use a database. And then the 'shutdown' can be made very short by synchronizing the new host's database with the old one just before cutover. Without a database concern, the usual approach is to leave the site up on the old server, switch the DNS to the new server's IP address, and then take down the old site after the DNS propagates completely -- usually only a few hours, but maybe a couple of days.

Jim