httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Warhurst, SI (Spencer) " <S.I.Warhu...@rl.ac.uk>
Subject RE: [users@httpd] Case Sensitivity
Date Fri, 19 Sep 2003 11:21:29 GMT
>     RewriteEngine On
>     RewriteCond d:/www/lists%{REQUEST_URI}.html -f
>     RewriteRule /(.*) c:/path/to/$1.html
> 
> There's probably a less hacky version of that RewriteCond, 
> but you get the
> idea: if the URI is /somelist, it tests if the file
> d:/www/lists/somelist.html exists, and if so rewrites the path. That
> requires that all URIs matches the HTML documents.

I've just been trying the rewrite method with the following lines in the
config:

RewriteCond d:/www/lists%{REQUEST_URI}.html -f
RewriteRule /(.*) d:/www/lists/$1.html

I get a 403 Forbidden error and this is what the rewrite log has to say
about it:

(2) init rewrite engine with requested uri /sw-test
(3) applying pattern '/(.*)' to uri '/sw-test'
(2) rewrite /sw-test -> d:/www/lists/sw-test.html
(2) local path result: d:/www/lists/sw-test.html
(2) prefixed with document_root to D:/www/webd:/www/lists/sw-test.html
(1) go-ahead with D:/www/webd:/www/lists/sw-test.html [OK]

So, it looks like it's going alright until the last two lines. I did a
search around the web and one site suggested that the prefixing with
document root is a bug in Apache 2 on the Windows platform.

I have tried a few variations on the rewriterule line, including specifying
the full host path, etc but I get worse errors than the above.

Is this a bug or has it been fixed and there's an easy answer?

Thanks

Spencer

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Mime
View raw message