When I write in .htaccess this mod_rewrite
RewriteEngine on
RewriteRule ^(.*)\.my_extension$ $1.php
and open url: site.com/index.my_extension this wroks fine, opened index.php
But when I am trying mod_rewrite like this:
RewriteEngine on
RewriteRule ^(.*)$ index.php?url=$1
this gives me Internal Server Error.
Why this happened? what is reason?
Have you enabled rewrite logging?--- if rewrite logging not enabled, then how firts rewriterule works?Are the two rewrite rules in the same config file?--- no, just one RewriteRule is in.htaccessfile.It can be possible that you could have a redirect/rewrite loop--- In other servers, catching all then redirecting to index.php works, and here why must happened redirect/rewrite loop? reason of this may be some option?