mod_rewrite: if browsing to site.com/folder, how do I ignore RewriteRules and retrieve the file?
am 28.09.2007 18:18:05 von johnhutch
Currently, my .htaccess looks like this:
1 Options +FollowSymLinks
2 RewriteEngine on
3
4 RewriteCond ^/meetings/* [NC]
5 RewriteRule .* - [L]
6
7 RewriteRule ^([A-Za-z_]+)/([A-Za-z_]+)/([A-Za-z_]+)/?$ /
index2.php?section=$1&subsection=$2&content=$3 [QSA,L]
8 RewriteRule ^([A-Za-z_]+)/([A-Za-z_]+)/?$ /index2.php?section=
$1&content=$2 [QSA,L]
9 RewriteRule ^([A-Za-z_]+)/?$ /index2.php?section=$1 [QSA,L]
10 RewriteRule ^$ /index.php [QSA,L]
If the user tries to browse to the meetings folder, they are all
separate sites not to be templated. So they need to browse straight
there. How can I accomplish this? My current code doesn't seem to work
as I'd expect.
Thanks in advance for any help you can offer!
Re: mod_rewrite: if browsing to site.com/folder, how do I ignore RewriteRules and retrieve the file?
am 28.09.2007 20:47:08 von HansH
"johnhutch" schreef in bericht
news:1190996285.502121.264230@g4g2000hsf.googlegroups.com...
> Currently, my .htaccess looks like this:
> 1 Options +FollowSymLinks
> 2 RewriteEngine on
> 3
> 4 RewriteCond ^/meetings/* [NC]
> 5 RewriteRule .* - [L]
> 6
> 7 RewriteRule ^([A-Za-z_]+)/([A-Za-z_]+)/([A-Za-z_]+)/?$ /
> index2.php?section=$1&subsection=$2&content=$3 [QSA,L]
> 8 RewriteRule ^([A-Za-z_]+)/([A-Za-z_]+)/?$ /index2.php?section=
> $1&content=$2 [QSA,L]
> 9 RewriteRule ^([A-Za-z_]+)/?$ /index2.php?section=$1 [QSA,L]
> 10 RewriteRule ^$ /index.php [QSA,L]
>
> If the user tries to browse to the meetings folder, they are all
> separate sites not to be templated. So they need to browse straight
> there. How can I accomplish this? My current code doesn't seem to work
> as I'd expect.
>
Rules in .htaccess tend to be a bit -rather a character- different, try
4 RewriteCond ^meetings/* [NC]
(that's without the leading slash)
HansH