i having problem on linux web server.
basically have following htaccess code:
<ifmodule mod_rewrite.c> rewriteengine on rewritebase / rewriterule ^index\.php$ - [l] rewritecond %{request_filename} !-f rewritecond %{request_filename} !-d rewriterule . /index.php [l] </ifmodule>
which works fine, if go www.mydomain.com/blablablajrehkhsg shows me www.mydomain.com/index.php page.
but doesn't work. example on specific uri www.mydomain.com/specific-uri 404 page not found error.
i tried add following line in htaccess
rewritecond %{request_uri} ^/specific-uri
so htaccess becomes:
<ifmodule mod_rewrite.c> rewriteengine on rewritebase / rewriterule ^index\.php$ - [l] rewritecond %{request_filename} !-f rewritecond %{request_filename} !-d rewritecond %{request_uri} ^/specific-uri rewriterule . /index.php [l] </ifmodule>
but still won't show mt index.php page.
please help, have no idea be.
thanks
ok, solved problem.
basically there page on root called specific-uri.php in conflict. the:
rewritecond %{request_filename} !-f
condition take care of this, think apache converting /specific-uri specific-uri.php before htaccess condition.
so added this:
options -multiviews
before condition in htaccess believe tells apache stop looking similar content uri.
now can see /specific-uri , specific-uri.php separetly.
Comments
Post a Comment