What's wrong with this Apache rewrite rule? -



What's wrong with this Apache rewrite rule? -

here's .htaccess:

rewriteengine on rewriterule ^([^/]+)$ /index.php?id=$1 [l]

and requests maintain causing 500.

you entering rewrite loop. alter this:

rewriteengine on rewritecond %{request_uri} !^/index\.php [nc] rewriterule ^([^/]+)$ /index.php?id=$1 [qsa,l]

or (should have same effect behind):

rewriteengine on rewritecond %{request_filename} !-f rewriterule ^([^/]+)$ /index.php?id=$1 [qsa,l]

apache mod-rewrite

Comments

Popular posts from this blog

c# - Move local mssql database to webhosted MYSQL -

java - How to pass parameters between Request-Scoped Controllers? -

string - what is the difference between "some" == "some\0" and strcmp("some","some\0") in c++? -