Re-directing domains
Moderator: General Moderators
-
spacebiscuit
- Forum Contributor
- Posts: 390
- Joined: Mon Mar 07, 2005 3:20 pm
Re-directing domains
Hi,
i'm not sure if this is the correct place to post this question but here goes.
I want a domain to redirect to another domain. I have seen the frames method of doing this but when I browse the target URL the address bar just displays the root address of the of the second domain regardless of the page(s) viewed.
I am sure I have seen a method whereby the URL is re-writeen or replace with the new doamin name and correctly displays the directory/structure of the target site?
Any ideas? Thanks in advance,
Rob.
i'm not sure if this is the correct place to post this question but here goes.
I want a domain to redirect to another domain. I have seen the frames method of doing this but when I browse the target URL the address bar just displays the root address of the of the second domain regardless of the page(s) viewed.
I am sure I have seen a method whereby the URL is re-writeen or replace with the new doamin name and correctly displays the directory/structure of the target site?
Any ideas? Thanks in advance,
Rob.
Re: Re-directing domains
Do you have access to your apache configuration files? If not, can you use an .htaccess file?
By the way - I've moved your thread to "Installation and Configuration". The previous forum wasn't wrong, but this one gets more traffic.
By the way - I've moved your thread to "Installation and Configuration". The previous forum wasn't wrong, but this one gets more traffic.
Real programmers don't comment their code. If it was hard to write, it should be hard to understand.
-
spacebiscuit
- Forum Contributor
- Posts: 390
- Joined: Mon Mar 07, 2005 3:20 pm
Re: Re-directing domains
I do not have direct access no, but could possible i fI ask my host.
What is the htaccess method?
Thanks,
Rob.
What is the htaccess method?
Thanks,
Rob.
Re: Re-directing domains
Do a Google for "htaccess redirect" or "htaccess domain redirect" - there are lots of tutorials out there.
Real programmers don't comment their code. If it was hard to write, it should be hard to understand.
-
spacebiscuit
- Forum Contributor
- Posts: 390
- Joined: Mon Mar 07, 2005 3:20 pm
Re: Re-directing domains
Are ou sure this method will display the new doamin in place of the original domain?
Thanks,
Rob.
Thanks,
Rob.
Re: Re-directing domains
I'm pretty sure - try it 
There are 10 types of people in this world, those who understand binary and those who don't
-
spacebiscuit
- Forum Contributor
- Posts: 390
- Joined: Mon Mar 07, 2005 3:20 pm
Re: Re-directing domains
No all I can find are methods which re-direct and display the target site's domain name. The only way I can find to use the new sites domain is by clocking but this uses frames which I do not want to use as it does not read my session variables.
Thanks,
Rob.
Thanks,
Rob.
Re: Re-directing domains
Depending on which tutorial you've found - it depends. Doing a "redirect" from domainA.com to domainB.com will forward any requests for domainA.com to domainB.com - so a user looking for http://www.domainA.com/ will be forwarded to http://www.domainB.com & see http://www.domainB.com in their address bar.
If you're interested in having http://www.domainB.com appear, but have http://www.domainA.com show in their address bar, you're looking for a "rewrite".
If you're interested in having http://www.domainB.com appear, but have http://www.domainA.com show in their address bar, you're looking for a "rewrite".
Real programmers don't comment their code. If it was hard to write, it should be hard to understand.
-
spacebiscuit
- Forum Contributor
- Posts: 390
- Joined: Mon Mar 07, 2005 3:20 pm
Re: Re-directing domains
I need a re-write then I guess.
Not only has domainA got to show in the address bar but it must also replace domainB in the address bar. Like I said cloaking/masking does not work as my session variables are then not read.
Thanks,
Rob.
Not only has domainA got to show in the address bar but it must also replace domainB in the address bar. Like I said cloaking/masking does not work as my session variables are then not read.
Thanks,
Rob.
Re: Re-directing domains
Well, look into mod_rewrite then.
Real programmers don't comment their code. If it was hard to write, it should be hard to understand.
-
spacebiscuit
- Forum Contributor
- Posts: 390
- Joined: Mon Mar 07, 2005 3:20 pm
Re: Re-directing domains
I am going around in circles - my google search keep bringing up papes that I have viewed hours ago.
Any links to a tutorial would be apprciated.
Many thanks,
Rob.
Any links to a tutorial would be apprciated.
Many thanks,
Rob.
Re: Re-directing domains
I don't know of any other than what Google would bring up.
Real programmers don't comment their code. If it was hard to write, it should be hard to understand.
-
spacebiscuit
- Forum Contributor
- Posts: 390
- Joined: Mon Mar 07, 2005 3:20 pm
Re: Re-directing domains
I actually don't think it is possible with the rewrite_mod - it has to be done server side with an alias.
Thanks,
Rob.
Thanks,
Rob.