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

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

Android soft keyboard reverts to default keyboard on orientation change -

Rendering JButton to get the JCheckBox behavior in a JTable by using images does not update my table -