Joost de Heer wrote:
Robert Ionescu wrote:Shyne wrote:Apparently the directive RewriteCond %{REQUEST_FILENAME} !-f matches requests for existing files, which it should exactly not do.We were able to analyze the RewriteLog in a German mod_rewrite forum. The problem here was the following: %{REQUEST_FILENAME} did contain the value from %{REQUEST_URI}, namely /help/abc but not the expected and needed full physical path /var/www/help/abc.Sounds like you're using rewrites in a .htaccess file. That results in directories at the beginning being chopped off.
No, the rules were placed in the virtualhost section, per-server context.I have never heard that ENVs are choped off in per-dir context, only the pattern of the RewriteRule is a filepath there (while a local URL in per-server context) which changes from the point where the .htaccess is placed (striped per-dir prefix). But the "problem" here is not the rule-pattern but the value of the ENV %{REQUEST_FILENAME} where (in per-server context) the filename field of request_rec contains the same value as the uri field does.
I think this is a logical behavior, because afaik the filename translation comes in a later step of processing, so the full physical path is simply not known in this step of processing.
I found also an assigned docs bug report from January 2003:http://issues.apache.org/bugzilla/show_bug.cgi?id=16402 but obviously it is not fixed yet.
At least the "average user" cannot read between the lines | the value of the filename field of the internal request_rec structure | of the Apache server. | (http://httpd.apache.org/docs/2.2/mod/mod_rewrite.html#rewritecond , | "Other things you should be aware of:")that filename does not (cannot) contain the full physical path in per-server context (if you don't perform an url-based sub-request lookup).
-- Robert --------------------------------------------------------------------- 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@xxxxxxxxxxxxxxxx " from the digest: users-digest-unsubscribe@xxxxxxxxxxxxxxxx For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx