
|
View Full Version : Multiple Domains to a Single Site?
humorthem 01-11-2001, 12:34 AM I need to know how to go about this. I did a search through the "archives" and couldn't answer this, so I'll risk embarassment with a basic question.
I have numerous domains stored at 000domains and want to point multiple domain names to a single site. In other words, I want to have mysite.com as the basic site, and have domainname2.com pull up mysite.com. domainname2.com could point to a different (mirror) page of the home page at mysite.com, but I want it to go to the same site.
Does this make any sense? Is this something that a service like redirection.net does? Is this something my host can do for me?
Thanks to you all for the free education I get from this site. It's great!
Greg
Vinay 01-11-2001, 01:14 AM ask your host, they should be able to set something as such up without much problems
------------------------------
Kryogen Technologies: NEW YEARPROMOTION (http://www.kryogen.com/webhosting.php)
Vinay 01-11-2001, 01:16 AM cant edit posts ? hmm, aah, nevermind.. my signature got all messed up
Martie 01-11-2001, 01:24 AM Vinay.....GOOOOOD..to see ya!!
schweiz 01-11-2001, 01:59 AM Some hosts do charge for domain pointers.
Or you can make use of free services courtesy of sites like zoneeedit.com or mydomain.com to point several domains to the same site.
Heya Vinay, nice to see ya again around here. Fix the sig up in your profile - colors are disabled around here.
Duster 01-11-2001, 03:22 AM Yes, it makes perfect sense and can be done, as others have pointed out. 000domains usually does it with the .net and .org extensions, thought they don't work since the recent move.
I do it with one of my domain names. Whether you enter it as .com, .net, or .org, you end up at the same place.
I just registered three new domains that will point to different sections of that same site.
A friend of mine (the one with the Dell server) has almost 150 domain names. Most of them just point to different parts of the same site.
allan 01-11-2001, 07:14 AM There are a couple of ways to do this. The easiest it simply to create a CNAME in the zone file for domain2 & domain3 pointing to domain1.
how will a cname help? a cname would be blah.domain1.com you cant put in a new domain unless you use a totally new soa record. each domain would have its own soa record pointing to the same ip is the only way to do it without using a redirection of some sort.
Steve
Chicken 01-11-2001, 07:49 PM I wondered about that one too. Have you figured out how to do this yet (humorthem)??? There are a few ways to accomplish this.
allan 01-11-2001, 09:25 PM Originally posted by Keeg
how will a cname help? a cname would be blah.domain1.com you cant put in a new domain unless you use a totally new soa record. each domain would have its own soa record pointing to the same ip is the only way to do it without using a redirection of some sort.
Maybe I misunderstood the question, but it sounds like he simply wants http://www.domain2.com & http://www.domain3.com to point to the same site as http://www.domain1.com.
In which case you would create a CNAME that points http://www.domain2.com to http://www.domain1.com, and that will do it.
For more information:
http://www.jhsoft.com/help/rec_CNAME.htm
Thanks
allan
humorthem 01-12-2001, 12:04 AM Thanks, all.
My host has graciously agreed to point an extra domain for me to my root web. If I want to point it towards a folder or subdomain, I can use re-direction.net. Redirection.net is only $15 per year, and includes e-mail on that domain, if I understand it correctly.
Every day is a learning experience, and you all are educating me more than you know.
Thanks,
Greg
allan 01-12-2001, 12:39 AM Originally posted by humorthem
My host has graciously agreed to point an extra domain for me to my root web. If I want to point it towards a folder or subdomain, I can use re-direction.net. Redirection.net is only $15 per year, and includes e-mail on that domain, if I understand it correctly.
Greg,
I apologize...I misunderstood your original question..
Will your current host allow you to set your default document as index.cgi? If they will you can use a script like this to do the redirection for you :)):
#!/usr/bin/perl
$home = "index.html";
%domains = (
'www.domain1.com' => 'domain1/',
'www.domain2.com' => 'domain2/',
'www.domain3.com' => 'domain3/',
);
$server = lc($ENV{'HTTP_HOST'});if ($ENV{'HTTP_HOST'} =~ /(\d+)\.(\d+)\.(\d+)\.(\d+)/){$t='/'}else{if ($server !~ /^www./){$server = 'www.' . $server;}}@domains = keys(%domains);foreach $domain(@domains){if ($domain eq $server){print "Location: http://${server}/$domains{$server}\n\n";$match="yes";last;exit}}unless ($match){print "Location: http://$server/$home\n\n"; exit}
exit;
pippen 01-12-2001, 01:05 AM To answer humorthem's question, I think u can open a free accout at MyDomain (http://www.mydomain.com) and use their IP Pointing. It works ONLY IF your main site has a static IP.
well based on the reply his current host gave im pretty sure im the current host :) anyway if he wants to set his start page to index.cgi and do as you suggested he can by using htaccess.
Steve
poohbie 01-14-2001, 02:01 PM Hmm, I heard of Tera-byte doing this for other people, but the support guy who responded to me wouldn't let me point an extra domain to my tera-byte account's root web.
I probably should've written to Steve instead.
gthorley 01-15-2001, 02:01 AM Originally posted by uuallan
[QUOTE]Originally posted by humorthem
#!/usr/bin/perl
$home = "index.html";
%domains = (
'www.domain1.com' => 'domain1/',
'www.domain2.com' => 'domain2/',
'www.domain3.com' => 'domain3/',
);
$server = lc($ENV{'HTTP_HOST'});if ($ENV{'HTTP_HOST'} =~ /(\d+)\.(\d+)\.(\d+)\.(\d+)/){$t='/'}else{if ($server !~ /^www./){$server = 'www.' . $server;}}@domains = keys(%domains);foreach $domain(@domains){if ($domain eq $server){print "Location: http://${server}/$domains{$server}\n\n";$match="yes";last;exit}}unless ($match){print "Location: http://$server/$home\n\n"; exit}
exit;
Could you clarify to confirm what is changed in the above script to accomplish the following. If the existing web name is http://www.mydomain.com and you wish to have it open mydomain.com/index.html and you have one more domain name called http://www.seconddomain.com which is being pointed to the same IP as mydomain.com and you want it to open index.html in a folder called seconddomain.
Chicken 01-15-2001, 09:43 AM Note that when you use these types of scripts, you MUST redirect the main domain as well!
#!/usr/bin/perl
$home = "index.html";
%domains = (
'www.mydomain.com' => 'mydomain/',
'www.seconddomain.com' => 'seconddomain/',
);
$server = lc($ENV{'HTTP_HOST'});if ($ENV{'HTTP_HOST'} =~ /(\d+)\.(\d+)\.(\d+)\.(\d+)/){$t='/'}else{if ($server !~ /^www./){$server = 'www.' . $server;}}@domains = keys(%domains);foreach $domain(@domains){if ($domain eq $server){print "Location: http://${server}/$domains{$server}\n\n";$match="yes";last;exit}}unless ($match){print "Location: http://$server/$home\n\n"; exit}
exit;
dgessler 01-15-2001, 11:03 AM So when you would go to a place like centralinfo.net where you get free dns to point your other domains to your main domains account but in a different directory, couldn't that be doone by doing it where you registered the domain from? Like have your other domains redirect somewhere.
Ingress 01-15-2001, 01:57 PM <<ADMIN EDIT>>
Post deleted due to breach of the forum rules (http://www.webhostlink.com/index.php?action=forum-rules)
<</ADMIN EDIT>>
[Edited by Chicken on 01-15-2001 at 01:34 PM]
Chicken 01-15-2001, 03:38 PM Originally posted by dgessler
So when you would go to a place like centralinfo.net where you get free dns to point your other domains to your main domains account but in a different directory, couldn't that be doone by doing it where you registered the domain from? Like have your other domains redirect somewhere.
I doubt it, unless your registrar has either DNS and/or domain forwarding options.
Basically, it is a three step process (simplified):
Registrar- Enter nameservers (ns1.something.com & ns2...).
Nameservers (DNS) - Direct domain to the proper server.
Server- Domain is resolved based upon IP address or directed further by the server itself (name based hosting).
Centralinfo would be the Nameserver (DNS) portion of the program.
One part of the picture you might be missing is that although you can set up whatever you like via Centralinfo, it has to match what is set up on the server (to a degree). With URL forwarding (a.k.a. path forwarding, URL redirection, etc.), this doesn't matter since you are just forwarding your domain to a URL (a folder).
If you just want to point a domain at another domain, (like pointing the .net of your .com domain), you can do this by simply using Centralinfo and having everything point to the IP address of your domain. Set an A record of www to also point to your domain, and MX, etc...
Confused yet? :)
gthorley 01-15-2001, 08:37 PM Originally posted by Chicken
Note that when you use these types of scripts, you MUST redirect the main domain as well!
#!/usr/bin/perl
$home = "index.html";
%domains = (
'www.mydomain.com' => 'mydomain/',
'www.seconddomain.com' => 'seconddomain/',
);
$server = lc($ENV{'HTTP_HOST'});if ($ENV{'HTTP_HOST'} =~ /(\d+)\.(\d+)\.(\d+)\.(\d+)/){$t='/'}else{if ($server !~ /^www./){$server = 'www.' . $server;}}@domains = keys(%domains);foreach $domain(@domains){if ($domain eq $server){print "Location: http://${server}/$domains{$server}\n\n";$match="yes";last;exit}}unless ($match){print "Location: http://$server/$home\n\n"; exit}
exit;
Chicken for this script to work does the index page for mydomain.com have to be in a seperate subfolder to the main web folder which would have index.cgi.
In 'www.mydomain.com' => 'mydomain/', what does 'mydomain/' represent? A folder? Could a file name in the primary web folder be placed their such as mydomain_index.shtml?
Chicken 01-15-2001, 09:27 PM I, let me tell you that I didn't write this, and have very little knowledge of these things. Two, I believe you can have the main domain's index.html file in with the index.cgi (and if I'm not mistaken, there is a catch default bulit into the script at the top - index.html).
There are folders listed, and I suppose, but not sure of the exact syntax, that you could direct it to a file instead. Might be as simple as just putting the file name there.
Also note, (one thing I *am* sure of), that you have to change it so that the server looks for index.cgi first, then index.html index.htm...
I really have to run as I am about to be late to pick up the wife (almost typed girlfriend, heh) at the mall and she is gonna kill me...
Hopefully by the time I get back, someone else can help if you have problems... I'll check back when I can.
Good luck and may the good chicken be with you...
poohbie send me an email steve@tera-byte.com and let me know who said taht so i can correct them please.
Steve
dgessler 01-16-2001, 04:21 PM the place i registered both of my domains (I registered these before i knew of the 9.99$ a year reg places like gkg.net, submerged-ideas.com, etc.) has a url cloaking/forwarding so that would make it easier, but i already have real hosting for all my domains now so that wont matter.
cmenterpises 02-02-2001, 09:34 PM Probably off topic, but I edited my httpd.conf virtual host list to point all my "camped" domains to the same home directory as my company web site. Is this a good or bad way to solve the domain pointing issue? bearing in mind all my domains are on the same server and I run DNS on a seperate box. I've just recently moved away from the Cobalt RAQ trap, so REAL linux issues are still giving me sleepless nights :)
Lee.
Chicken 02-03-2001, 12:19 AM Good on anything but a RaQ, or possibly a server running plesk. Otherwise this would be fine...
cmenterpises 02-03-2001, 04:54 AM It sounds daft I know, but the only time I'll ever touch a raq again is when i'm setting it up for one of my clients. I'm enjoying the freedom one gets with having a custom built, custom installed Linux box. I can actaully get it to do things, I mean real kewl stuff :D
Cheers,
Lee.
Chicken 02-03-2001, 10:27 AM I hear you. Though plesk and the RaQ OS make some things easier, they also create a couple of problems as well.
javapie 02-16-2001, 11:25 PM Our team just got through designing a simpe perl script that will allow you to redirect pointer sites to different folders. You can check it out at <<ADMIN EDIT: Please post in Advertsing Forum>>
I hope this helps you.
[Edited by Chicken on 02-17-2001 at 12:39 AM]
gthorley 02-17-2001, 12:44 AM I notice the cost is $25.00.
It would certainly be worth $25 if it did everything someone wanted. Do you have to alter htaccess file for this script to work?
Anyone know of any shareware or free scripts out there that will do this which don't require a change to htaccess?
SickofAds 02-17-2001, 12:49 AM I think there's a bunch of them out there, actually. Hotscripts lists both perl and php scripts, some free, some not.
http://www.hotscripts.com/Perl/Scripts_and_Programs/Redirection/
http://www.hotscripts.com/PHP/Scripts_and_Programs/Redirection/
I have no idea if any of them work or not, because I haven't the faintest idea about scripting or making entries in server files, except that it can be done. :)
|