Mod_rewrite issues
Posted: Thu Jan 20, 2005 1:30 pm
Trying to design a set of rules to follow, unless the file requested already exists.
Basically I want tutorials/somefile_that_doesnt_exist to be processed by my rules, but /tutorials/file_that_does_exists.php will just bypass my rules
Heres what I've got so far, what it does it it just goes to debug.php and $debug = /tutorials/debug.php
Does this no matter what file I request, even If I just request /
Basically I want tutorials/somefile_that_doesnt_exist to be processed by my rules, but /tutorials/file_that_does_exists.php will just bypass my rules
Heres what I've got so far, what it does it it just goes to debug.php and $debug = /tutorials/debug.php
Does this no matter what file I request, even If I just request /
Code: Select all
RewriteEngine on
RewriteCond %{REQUEST_URI} !-f
RewriteRule ^(.*) tutorials/debug.php?debug=%{REQUEST_URI}