Groups keyboard shortcuts have been updated
Dismiss
See shortcuts

What does this mod rewrite do?

5 views
Skip to first unread message

noagbod...@gmail.com

unread,
Oct 22, 2007, 7:37:31 PM10/22/07
to Apache .htaccess
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} -f [NC,OR]
RewriteCond %{REQUEST_FILENAME} -d [NC]
RewriteRule .* - [L]
RewriteRule ^(.+)$ index?_rewrite_sticky=$1 [QSA,L]
</IfModule>

Apache Admin

unread,
Nov 8, 2007, 12:13:39 AM11/8/07
to Apache .htaccess
The "IfModule" says only work when the mod_rewrite.c module
(mod_rewrite.so) is loaded.

It is then saying, if the Requested filename is not found on the
server, and if it is also not a valid directory "RewriteCond %
{REQUEST_FILENAME} -d", then Rewrite ALL requests to nowhere.. hmm.
The last rule rewrites all requests to index?_rewrite_sticky=(whatever
the request was for.) At first glance it appears it only does that
for files that ARE found.

On Oct 22, 6:37 pm, "noagbodjivic...@gmail.com"

Reply all
Reply to author
Forward
0 new messages