title: .htaccess Rewrite 505 Error Loop
body: <p>I am trying to rewrite:</p>
  
  <p>mydomain.com/category.php?id=cat</p>
  
  <p>to</p>
  
  <p>mydomain.com/cat</p>
  
  <p>I have used the following .htaccess code but it keeps showing a 505 error:</p>
  
  <pre><code>RewriteEngine On
  RewriteRule ^([^/]*)$ /category.php?id=$1 [L]
  </code></pre>
  
  <p>I read on another page that it is because the page keeps looping, but I can't work out how I can fix the code.</p>