Subdomain.domain.com -> domain.com. Not working :(

Dantist

Verified User
Joined
Jan 5, 2008
Messages
8
Hi!
I have migrated from one hosting to another..
On my previous one I use such a scheme:
1. At "DNS Management" inside the User Level I make new A record, which define * to go on main domain IP..
2. Inside public_html of my domain I'd created .htaccess which "parse" the subdomain from RequestURL and send appropriate content...

Now I have problem on my new virtual hosting.. When I create a * A record all subdomains begin to resolve, but the server is sending "Apache Test Page" to the client.. The one, which starts with "Hey, it worked ! The SSL/TLS-aware Apache webserver was successfully installed on this website...".

Hosters says, that i have to get dedicate IP for this scheme to start working..

Is it true?..
Can I do such a thing (redirects all subdomain to main public_html dir) on shared IP?.. How can I do it?..

Thanks!
 
You can't do it on a shared IP# unless you have direct access to the main httpd.conf file.

Why? Because shared IP hosting is really known as "name-based hosting" so the name has to be known; it can't be discerned from the http headers.

So in short you can do this either with your own server on a shared IP#, or on a shared hosting server with your own IP#.

Jeff
 
Back
Top