virtual hosts again

Jun 22, 2010 at 4:00 PM
hi, i am using the following rule to create a virtual host for users: RewriteCond %{HTTP_HOST} ^(?!www)([^.]+)\.mysite\.de [I] RewriteRule ^/(.*) /user.aspx?username=*1 [L,I] the rule is redirecting to the following url: this changes my desired functionality because it should be redirecting to the following url: any ideas on what i can do? cheers
Jun 23, 2010 at 6:45 PM
please does anyone have an idea about how i can modify this rule?
Jun 23, 2010 at 7:29 PM
please can you help me, i really need some help
Jun 23, 2010 at 7:52 PM
You have to make the RewriteRule absolute, or it will use the HTTP_HOST that the request is coming in on: RewriteRule ^/(.*)*1 [L,I]
Jun 23, 2010 at 8:19 PM
i've tried that but i get a 404.4 - no associated handler. the documentation also says you can't specify url schemes in a rewrite rule. perhaps i need to configure the handler mappings in iis?
Jun 24, 2010 at 2:35 AM
Try using RedirectRule
Jun 24, 2010 at 12:16 PM
using a redirect rule would send a response to the user agent and effectively change the value in the browser address bar, the user should not see the redirected url in their browser.
Jun 24, 2010 at 2:27 PM
Then you will have to use ProxyPass to transparently proxy to the new url
Jun 24, 2010 at 5:18 PM
tnx! that did the trick.