I'm trying to create a url handler by using php and .htaccess, my problem is that I don't know how to use rewrite condition only if the file\directory entered in the url does not exists.
Please have a look at this RewriteCond
resource.
RewriteCond %{REQUEST_FILENAME} !-f
// ^ this means file.
RewriteCond %{REQUEST_FILENAME} !-d
// ^ this means NOT, "d" means directory.
// Your rewrite rule here.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With