title: Rewrite rule preserving post data
body: <p>I'm trying to build a rewrite rule. I cannot redirect because I need to preserve POST and GET data. In particular, if not present I need to add the string "v1". So:</p>
  
  <p><a href="http://www.example.com/" rel="nofollow">http://www.example.com/</a> -> <a href="http://www.example.com/v1" rel="nofollow">http://www.example.com/v1</a></p>
  
  <p>I tried:</p>
  
  <pre><code>RewriteEngine On
  RewriteRule "/(.*)$" "/v1/$1" [NC,L]
  </code></pre>
  
  <p>But this is not working. Can you help me please?</p>
  
  <p>EDIT: with the first answer:</p>
  
  <pre><code>RewriteRule !^/?v1/ /v1%{REQUEST_URI} [NC,L]
  
  http://www.example.com -&gt; OK
  http://www.example.com/v1 -&gt; not preserving POST data (GET OK)
  http://www.example.com/v1/ -&gt; OK, please why (I just added a slash after v1, but this is not the solution I'm looking for)?
  </code></pre>