Webmaster Forum


Go Back   Webmaster Forum > Web Development > Coding Forum

Coding Forum Problems with your code? Discuss coding issues, including JavaScript, PHP & MySQL, HTML & CSS, Flash & ActionScript, and more.


Reply
 
LinkBack Thread Tools Display Modes
Share |
  #1 (permalink)  
Old 01-23-2004, 12:06 PM
Contributing Member
Latest Blog:
None

 
Join Date: 10-13-03
Location: Hofstade-Zemst, Belgium
Posts: 53
iTrader: 0 / 0%
.htaccess redirect to new webspace

Hello,

I am reading a few tips on another website where they ask you -in case you change servers- you need to add some code in your old .htacess-file on your old server to redirect to your new webspace:

[code:1:cd45be6ed2]If all is well, modify .htaccess on your server at X to force any new requests to the new server at Y. Hence, any requests to your domain will be re-routed to the IP of the server at Y. [/code:1:cd45be6ed2]

Does anyone of you know which code that I need to enter in the .htaccess file?

All help welcome! greetings,

Bart
__________________
Luchtzak Aviation
 
Reply With Quote
  #2 (permalink)  
Old 01-23-2004, 12:36 PM
hatchet's Avatar
Senior Member
Latest Blog:
None

 
Join Date: 10-11-03
Posts: 833
iTrader: 0 / 0%
Redirect / http://www.yoursite.com

That's all on one line.. the first slash is the root of your current server and then a space.. then new server. I don't really see the benefit in that.. but oh well. That is mainly used for forwarding to something where only a portion or one page has been moved to a different server.
Once the DNS updates (a couple days) it will be unnecessary anyway.
 
Reply With Quote
  #3 (permalink)  
Old 01-23-2004, 02:32 PM
kwvarga's Avatar
v7n Mentor
 
Join Date: 10-13-03
Location: Tuscaloosa, AL or Atlanta
Posts: 2,527
iTrader: 0 / 0%
Redirect /olddirectory http://yoursite.com/newdirectory/

so you can redirect directories.. thats why they have / there.. a / will just do everything /forum will just redirect a forum.
 
Reply With Quote
  #4 (permalink)  
Old 01-23-2004, 06:29 PM
hatchet's Avatar
Senior Member
Latest Blog:
None

 
Join Date: 10-11-03
Posts: 833
iTrader: 0 / 0%
Uhhhh.. yeah that's what I said. But he is moving a domain from one server to another. I don't see the sense in doing it for 2 days. Just make a page and say go here.
Now if he wanted to redirect one domain name to another domain name - that's different.
I wouldn't bother answering the post if I didn't know what I was saying.
 
Reply With Quote
  #5 (permalink)  
Old 01-23-2004, 06:30 PM
kwvarga's Avatar
v7n Mentor
 
Join Date: 10-13-03
Location: Tuscaloosa, AL or Atlanta
Posts: 2,527
iTrader: 0 / 0%
oh.. i thought your quote
Quote:
don't really see the benefit in that.. but oh well
was saying you dindt know about the / sorry about that hatchet :0
 
Reply With Quote
  #6 (permalink)  
Old 01-23-2004, 09:24 PM
hatchet's Avatar
Senior Member
Latest Blog:
None

 
Join Date: 10-11-03
Posts: 833
iTrader: 0 / 0%
oh.. no I just don't see what the redirecting of a whole site to a new domain is worth.. DNS typically updates in a couple days and you're back in business. Seems easier to put a temp index page there with - "Hey were are moving our domain to a new server which is located right <ahref=blahblah>here</a> until the DNS updates".
 
Reply With Quote
  #7 (permalink)  
Old 01-23-2004, 10:05 PM
sim sim is offline
Banned
Latest Blog:
None

 
Join Date: 01-23-04
Posts: 1,098
iTrader: 0 / 0%
or just throw a index.php page in there and redirect it where ever untill you get you DNS updated.
 
Reply With Quote
  #8 (permalink)  
Old 01-25-2004, 08:56 AM
LazyJim's Avatar
v7n Mentor
Latest Blog:
None

 
Join Date: 10-13-03
Location: UK
Posts: 2,469
iTrader: 0 / 0%
using the .htaccess redirect, what URL shows up in the browser???
__________________

-LJ-

My advice is to look at each case individually, with an informed mind and an appropriately balanced and objective viewpoint.

Web Design and Development, Ipswich, UK.
My deviantArt
 
Reply With Quote
Go Back   Webmaster Forum > Web Development > Coding Forum

Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
.htaccess 301 redirect modine Coding Forum 14 06-12-2007 11:28 AM
htaccess 301 redirect esiason14 Coding Forum 2 01-31-2007 11:44 AM
.htaccess redirect problem..! Immo Coding Forum 16 08-03-2006 04:02 AM
.htaccess redirect question Pimpen 2010 Coding Forum 4 04-04-2006 10:34 AM
htaccess/mod rewrite help to redirect subdomain to a domain Thanol Coding Forum 0 07-19-2004 09:36 AM


V7N Network
Get exposure! V7N I Love Photography V7N SEO Blog V7N Directory


All times are GMT -7. The time now is 06:13 PM.
Powered by vBulletin
Copyright © 2000-2013 Jelsoft Enterprises Limited.
Copyright © 2003 - 2013 Escalate Media LP




Search Engine Optimization by vBSEO 3.6.0 RC 2 ©2011, Crawlability, Inc.