Welcome to WebmasterWorld Guest from 54.196.244.186

Forum Moderators: Ocean10000 & incrediBILL & phranque

Message Too Old, No Replies

.htaccess interfering with addon domain

is this normal?

     
10:38 am on Aug 21, 2005 (gmt 0)

Junior Member

10+ Year Member

joined:Dec 18, 2003
posts:58
votes: 0


I have an account with several addon domains(created via cpanel), Problem is the main account has a .htaccess doing some url rewriting, and its interfering with the addon domains. :(

Is this to be expected of is the server setup incorrectly?

thanks

3:03 pm on Aug 21, 2005 (gmt 0)

Senior Member

WebmasterWorld Senior Member jdmorgan is a WebmasterWorld Top Contributor of All Time 10+ Year Member

joined:Mar 31, 2002
posts:25430
votes: 0


That all depends on exactly how the server is set up, and the location of the code that is doing the rewriting.

If you are rewriting in .htaccess, and all "addon domains" share this .htaccess file, then the code in that file will have to be made "domain sensitive" by testing the requested HTTP_HOST before rewriting. The basic element is:


RewriteCond %{HTTP_HOST} ^www\.example\.com

where "www\.example\.com" is your domain with literal periods escaped as shown.

How you would then use the result of this test depends on exactly what you are trying to do with the rewrites.

Jim
[edit] Speling. [/edit]

 

Join The Conversation

Moderators and Top Contributors

Hot Threads This Week

Featured Threads

Free SEO Tools

Hire Expert Members