httpd-docs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From hernan gonzalez <hgonza...@gmail.com>
Subject sample regex patterns are mildly confusing
Date Fri, 08 Apr 2011 14:03:31 GMT
Issue commented here

   http://stackoverflow.com/questions/5587148/regex-patterns-in-apache-rewritecond-and-friends-full-or-partial-match

It feels redundant and confusing to me to write (a single example
among many others in the docs) :

             RewriteCond  %{HTTP_USER_AGENT}  ^Mozilla.*

when the .* is really not need - confusing, because it might lead to
believe that Apache is trying a full match, i.e. matching the full
string.

It would be neater and cleaner to write instead

              RewriteCond  %{HTTP_USER_AGENT}  ^Mozilla

Regards

------------------------------------------------------------------------------
H. Gonzalez

---------------------------------------------------------------------
To unsubscribe, e-mail: docs-unsubscribe@httpd.apache.org
For additional commands, e-mail: docs-help@httpd.apache.org


Mime
View raw message