[Gllug] mod rewrite

Sean Burlington sean at uncertainty.org.uk
Thu Sep 22 11:34:24 UTC 2005


Hi all,
	I want to set up apache so that all requests are redirected to a CMS -
except some specified URLs

I also want the CMS to use simple URLs that people might email to each
other.

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...

Can anyone point out why the following alternatives don't work?

RewriteCond %{REQUEST_URI}
!^/(photos)|(reporttool)|(R)|(walker)|(map)|(cgi-bin)|(stats)|(groups)|(files)/


RewriteCond %{REQUEST_URI}
!(^/(photos)|(reporttool)|(R)|(walker)|(map)|(cgi-bin)|(stats)|(groups)|(files)/)


-- 

Sean

-- 
Gllug mailing list  -  Gllug at gllug.org.uk
http://lists.gllug.org.uk/mailman/listinfo/gllug




More information about the GLLUG mailing list