php - Apache mod_rewrite ignore some real directories -


that's root directory:

css img js includes templates api 

and that's .htaccess

rewriteengine on rewritebase / rewritecond %{script_filename} !-f rewritecond %{script_filename} !-d rewriterule ^(.*)$ /index.php?ur=$1 [l,qsa] 

it works fine when inform url directory exists, apache open directory, when in fact should inform uri ur parameter.

for example: mydomain.com/test-uri/ goes ur parameter. mydomain.com/api/ apache loads api directory.

i did research, got consider directories when need pass api directory parameter.

remove -d check:

rewriteengine on rewritebase / rewritecond %{script_filename} !-f rewriterule ^(.*)$ /index.php?ur=$1 [l,qsa] 

Comments

Popular posts from this blog

user interface - how to replace an ongoing process of image capture from another process call over the same ImageLabel in python's GUI TKinter -

javascript - Using jquery append to add option values into a select element not working -

javascript - Restarting Supervisor and effect on FlaskSocketIO -