[Gllug] mod rewrite
Tom Schutzer-Weissmann
trmsw at yahoo.co.uk
Thu Sep 22 12:28:15 UTC 2005
On Thu, 2005-09-22 at 12:34 +0100, Sean Burlington wrote:
> I have a set of rules that work:
>
> RewriteCond %{REQUEST_URI}
> !((^/photos/)|(^/walker/)|(^/R/)|(^/reporttool/)|(^/map/)|(^/cgi-bin/)|(^/stats/)|(^/groups/)|(^/files/))
> RewriteRule ^/([^/]+)/$ /frontend/index.php?path1=$1 [PT,L]
>
>
> I'm just irritated that I'm missing something simpler and less error
> prone...
Don't know about simplicity, but in terms of readability:
- isn't REQUEST_URI assumed by default, so you could leave that out?
- a series of multiple RewriteCond clauses applies in combination to the
RewriteRule that follows it, so instead of one long line separated by
"|"s you could have
RewriteCond ^/photos
RewriteCond ^/reporttool
etc.
TomSW
___________________________________________________________
To help you stay safe and secure online, we've developed the all new Yahoo! Security Centre. http://uk.security.yahoo.com
--
Gllug mailing list - Gllug at gllug.org.uk
http://lists.gllug.org.uk/mailman/listinfo/gllug
More information about the GLLUG
mailing list