title: htaccess rewrite rule does not work
body: <p>I am facing problem with rewrite rule in htaccess file. Please help.</p>
  
  <p>This is my current htaccess file</p>
  
  <pre><code>&lt;IfModule mod_rewrite.c&gt;
  RewriteEngine On
  RewriteBase /product-project/
  RewriteRule . index.php [L]
  &lt;/IfModule&gt;
  </code></pre>
  
  <p>Now I want to create a rewrite rule such as "product/category/id" should redirect to "product/profile?profile_id=id". For this I have used </p>
  
  <pre><code>RewriteRule ^product/.*/(.*)$ product/profile?profile_id=$1 [L,R]
  </code></pre>
  
  <p>which is working fine in some way.</p>
  
  <p>1st problem ->  It is redirecting properly, but URL also changes. It should stay as "product/category/10", if I use the id as 10. But when I use this, it is redirecting properly, but URL changes to "product/profile?profile_id=10". I read somewhere to use [L,P] instead of [L,R] , but it is giving as Server error. </p>
  
  <p>2nd problem -> Now I want to create a new rewrite rule such as "product/id" should also redirect to "product/profile?profile_id=id". For this I have used </p>
  
  <pre><code>RewriteRule ^product/(.*)$ product/profile?profile_id=$1 [L,R]
  </code></pre>
  
  <p>Now this is not working &amp; showing server error</p>
  
  <p>3rd Problem -> Can I also create a new rewrite rule such as "/id" should also redirect to "product/profile?profile_id=id". Is this possible ?</p>
  
  <p>4th Problem -> Can I also create a new rewrite rule such as "/id1/id2" should also redirect to "product/profile?profile_id=id1&amp;serial_id=id2". Is this possible ?</p>
  
  <p>Thanks in advance for your time. </p>