Subdomain redirection issue

sionna.ch

New member
Joined
Aug 16, 2008
Messages
4
I'm having this problem with redirection with subdomains and hope someone here can help.

Here is the scenario:

I have a domain, www.domain.com
I have created a subdomain, blog.domain.com, which contains an index.html file.
When browsing to blog.domain.com, the contents of the index.html file are displayed and all is well.

Now, if I remove the index.html file and replace it with (a valid PHP) index.php, when browsing to blog.domain.com, it now automatically loads index.php from www.domain.com.

Am not sure why this is happening. I've performed some Google searchs and tried various redirects in the .htaccess file but to no avail.

What ideally I want is that browsing to blog.domain.com loads the index.php file from that directory and displays blog.domain.com in the browser.

Has anyone come across this before and has a solution? Any help would be much appreciated. Thanks in advance!
 
Is there a .htaccess file in the public_html directory or blog directory?
 
Is there a .htaccess file in the public_html directory or blog directory?

There was one in the public_html directory, but it was empty. I just removed it to see what would happen, but it's still the same result.
 
I cannot get blog.domain.com to work at all. Are you sure you own domain.com?

See HERE
 
My apologies for obscuring, I was only asking for a theoretical answer.

Any suggestions?
 
Back
Top