domain.com/xxx -> xxx.domain.com gets redirected to provi

Using a single web hosting account to host multiple sites

domain.com/xxx -> xxx.domain.com gets redirected to provi

Postby Ragnarok » Thu Apr 26, 2007 8:34 pm

I want to know if its possible what i want,

i have a community scripy running , it uses a verry extensive mod_rewrite. But i want to add a rewrite rule so people can access there profile trough a subdomain link.
http://domain.nl/xxx/ -> http://xxx/domain.nl (xxx = username)

http://domain.nl/xxx/ <- is already rewriten by mod_rewrite.
Code: Select all
RewriteRule ^([A-Za-z0-9]+)(\/)?$ profile/index.php?profile_name=$1
RewriteRule ^([A-Za-z0-9]+)\/profile(\/)?$ profile/index.php?profile_name=$1
RewriteRule ^([A-Za-z0-9]+)\/tags(\/)?$ search/personaltags.php?profile_name=$1
RewriteRule ^(([A-Za-z0-9])[A-Za-z0-9]+)\/rss\/?$ _rss/static.php?username=$1&userref=$2&type=profile
RewriteRule ^([A-Za-z0-9]+)\/rss\/(.+)\/?$ profile/rss2.php?profile_name=$1&tag=$2


The code below i found here on the forum, and as far as i can say it works.
Code: Select all
RewriteCond %{HTTP_HOST} ^(www\.)?mijnblogonline.nl\.nl$ [NC]
RewriteRule ^/([^/]+)(/(.*))?$ http://$1.mijnblogonline.nl/$3 [R=301,L]
[/code]
But now the problem when i go to xxx.domein.nl it redirects me to my hosting provider.
I checked my DNS and there is a "A" record wich points to *.domein.nl.

I asked my provider if they could do something for me but i still didnt got a answer. (6 weeks ago :( )

So i hope its possible what i want and that you can point me in the right direction.

THNX
Ragnarok
 
Posts: 1
Joined: Thu Apr 26, 2007 7:49 pm

Postby richardk » Fri Apr 27, 2007 10:28 am

But now the problem when i go to xxx.domein.nl it redirects me to my hosting provider.
I checked my DNS and there is a "A" record wich points to *.domein.nl.

The server has to be configured to send the requests to your document root (or wherever the .htaccess file is) before the mod_rewrite can be processed. You'll have to contact your host again.
richardk
 
Posts: 8800
Joined: Wed Dec 21, 2005 7:50 am


Return to Domain Handling

Who is online

Users browsing this forum: No registered users and 89 guests

cron