title: mod_rewrite and double slash issue
body: <p>I applied the following <code>mod_rewrite</code> rule in <code>Apache2</code> to redirect from non-www to www:</p>
  <pre><code>RewriteEngine On
  RewriteCond %{HTTP_HOST} ^example\.com$ [NC]
  RewriteRule ^(.*)$ http://www.example.com/$1 [R=301,L]
  </code></pre>
  <p>However, there's a double slash issue:</p>
  <ul>
  <li>When I go to <code>http://www.example.com</code> it
  correctly rewrites the URL to
  <code>http://www.example.com/</code></li>
  <li>When I go to
  <code>http://www.example.com/somepage</code>, it correctly
  rewrites the URL to
  <code>http://www.example.com/somepage</code></li>
  <li><strong>If I
  go to <code>http://example.com</code>, it
  rewrites the URL to
  <code>http://www.example.com//</code></strong> (double final slash)</li>
  <li>If I go to
  <code>http://example.com/somepage</code>, it
  correctly rewrites it to
  <code>http://www.example.com/somepage</code></li>
  </ul>
  <p>Is my configuration good for SEO?</p>