httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jori Mantysalo <>
Subject [users@httpd] RewriteRule: From x.a.b to y.a.b:nn/...
Date Mon, 31 May 2004 07:41:34 GMT
I have a server that has A-records "service.a.b" and "realname.a.b". I
have a service at address "http://realname.a.b:1234/some/service". I want
that service to be available at address "http://service.a.b". So I did
this at service.a.b:s DocumentRoot .htaccess:
 RewriteEngine on
 RewriteRule ^$ http://realname.a.b:1234/some/service [R]
and I had also tested
 RewriteRule ^(.*)$ http://realname.a.b:1234/some/service [R]

Last one works when I try URL "http://service.a.b/xxx", where 'xxx' can be
anything. But plain "http://service.a.b" does not work. Should it work?

(Later there might be one computer just for service.a.b. Just now there is
not, and URL must be printed on some cards and so on. That's why I need
this. I made a PHP-script that has only one header-command and it works,
but I would like to understand why I can't do this with Apache.)

Jori Mäntysalo
TAUCHI / Tietojenkäsittelytieteiden laitos / Tampereen yliopisto
Puh. 03-2158893, email, kotisivu

The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:> for more info.
To unsubscribe, e-mail:
   "   from the digest:
For additional commands, e-mail:

View raw message