Results 1 to 10 of 10
Thread: Mapping 1 domain to another.
-
02-05-2004, 09:39 AM #1WHT Addict
- Join Date
- May 2003
- Location
- Planet Earth
- Posts
- 113
Mapping 1 domain to another.
I have a domain eg. mydomain.com and bought another eg. mydomains.com.
Is there anyway i can map mydomains.com to mydomain.com such that if anyone types:
mydomains.com/something/blar.php, it will redirect to: mydomain.com/something/blar.php
is this possible?
-
02-05-2004, 09:51 AM #2Aspiring Evangelist
- Join Date
- Nov 2002
- Location
- Central Florida, USA
- Posts
- 380
If you want the actual domain to change, not just share the same content the easiest way would likely be .htaccess. If you have cpanel as your hosting control panel you can create this with the redirection option in cpanel.
Or you could created a file in your web directory called
.htaccess and add the following:
RedirectMatch mydomains.com/something/blar.php mydomain.com/something/blar.php
All on the same line with a space between the two domains.Rob
Founder and former owner of SRLnet. Sold in 2006
-
02-05-2004, 09:56 AM #3Junior Guru
- Join Date
- Jun 2003
- Location
- Norway
- Posts
- 206
Do you want it to redirect, or only show the same pages?
If you want both domains to show same content, you can
add a parked domain.
If you need forewarding, a little php or perl script
would be a good solution.
Feel free to message me if you need a script for that. It`s
only a few lines, and I could write one for you for free.Handy Host - Shared Web Hosting
http://www.handyhost.com - 24/7 support, 99.9% uptime guarantee, instant setup - support@handyhost.com
-
02-05-2004, 09:57 AM #4Junior Guru
- Join Date
- Jun 2003
- Location
- Norway
- Posts
- 206
Ops, SRLHosting you beat me to it
Handy Host - Shared Web Hosting
http://www.handyhost.com - 24/7 support, 99.9% uptime guarantee, instant setup - support@handyhost.com
-
02-05-2004, 10:00 AM #5Aspiring Evangelist
- Join Date
- Nov 2002
- Location
- Central Florida, USA
- Posts
- 380
Not quite, different solutions.
Rob
Founder and former owner of SRLnet. Sold in 2006
-
02-05-2004, 10:02 AM #6Junior Guru
- Join Date
- Jun 2003
- Location
- Norway
- Posts
- 206
Yes. Your solutions sound better. I just made up a solution with the perl script that would require nothing else from server than perl or php access. Also thought he wanted a generic solution for all domains. Probably that can also be done using .htaccess ?
Handy Host - Shared Web Hosting
http://www.handyhost.com - 24/7 support, 99.9% uptime guarantee, instant setup - support@handyhost.com
-
02-05-2004, 10:18 PM #7WHT Addict
- Join Date
- May 2003
- Location
- Planet Earth
- Posts
- 113
I am looking for one that will forward one domain to another.
If i use .htaccess, do I have to create entries for each URL I want to forward? As there will be a forum, blog.
thanksHello World!
-
02-05-2004, 10:35 PM #8Aspiring Evangelist
- Join Date
- Nov 2002
- Location
- Central Florida, USA
- Posts
- 380
.htaccess does support wildcards, so you may be able to work something out with that.
Here is a link to some .htaccess tips. http://www.javascriptkit.com/howto/htaccess.shtmlRob
Founder and former owner of SRLnet. Sold in 2006
-
02-05-2004, 10:42 PM #9WHT Addict
- Join Date
- May 2003
- Location
- Planet Earth
- Posts
- 113
Originally posted by SRLHosting
.htaccess does support wildcards, so you may be able to work something out with that.
Here is a link to some .htaccess tips. http://www.javascriptkit.com/howto/htaccess.shtml
thank you.Hello World!
-
02-06-2004, 06:42 AM #10Web Hosting Master
- Join Date
- Feb 2004
- Posts
- 772
Hi,
Write a redirection in .htaccess file as follows.
redirect permanent /something/blar.php
mydomain.com/something/blar.php
So, that if you give this URL mydomains.com/something/blar.php, it will automatically redirect to mydomain.com/something/blar.php
Regards.