You are viewing a plain text version of this content. The canonical link for it is here.
Posted to apache-bugdb@apache.org by Nguyen Truong Sinh <n....@vnnews.com> on 2001/02/06 04:20:41 UTC
mod_rewrite doesnt work properly on apache 1.3.14 and 1.3.17
Dear everybody,
I've used Apache 1.3.12 with mod_write enable to host some virtual hosts on
my sever (see the script below) and everything gone well. But after updating
Apache to 1.3.14 or 1.3.17, mod_write does not working properly, though I
used the same httpd.conf, everything else are the same as I used with Apache
1.3.12. Then what's wrong with this? And how to fix it ?
Thanks so much.
########################################
# rewrite script in httpd.conf
########################################
RewriteEngine on
RewriteMap lowercase int:tolower
# define the map file
RewriteMap vhost txt:/www/conf/vhost.map
# deal with aliases as above
RewriteCond %{REQUEST_URI} !^/icons/
RewriteCond %{REQUEST_URI} !^/cgi-bin/
RewriteCond ${lowercase:%{SERVER_NAME}} ^(.+)$
# this does the file-based remap
RewriteCond ${vhost:%1} ^(/.*)$
RewriteRule ^/(.*)$ %1/docs/$1
RewriteCond %{REQUEST_URI} ^/cgi-bin/
RewriteCond ${lowercase:%{SERVER_NAME}} ^(.+)$
RewriteCond ${vhost:%1} ^(/.*)$
RewriteRule ^/(.*)$ %1/cgi-bin/$1