TomH30: Rewrite Rule Subdomain ohne Änderung URL

Beitrag lesen

Hallo!

Ich möchte, dass beim Aufruf von test.domain.foo auf domain.foo/test.php weitergelietet wird. Dieses habe ich so erreicht:

Extract the subdomain part of domain.com

RewriteCond %{HTTP_HOST} ^([^.]+).domain.foo$ [NC]

Check that the subdomain part is not www and ftp and mail

RewriteCond %1 !^(www|ftp|mail)$ [NC]

Redirect all requests to a php script passing as argument the subdomain

RewriteRule ^.*$ http://www.domain.foo/test.php [R,L]

Allerdings ändert sich auch die URL. Gibt es eine Möglichkeit, dass sich die URL nicht ändert, sondern (zumindest bis was weiteres geklickt wird) test.domain.foo in der Browserzeile bleibt (wenn möglich ohne Frame).

Grüße und Danke, Tom