title: Apache mod_rewrite - want a file system redirect not a 301 redirect
body: <p>I have example1.com on a shared web host running Apache.  It has a directory example1.com/foo.  I now want example2.com to serve the same content from example1.com/foo, except at the example2.com root without the intervening directory in the URL.  Like example2.com/bar.html should serve the same content as example1.com/foo/bar.html .</p>
  
  <pre><code>RewriteEngine on
  RewriteCond %{HTTP_HOST} example2.com$ [NC]
  RewriteRule ^(.*)$ foo/$1 [NC]
  </code></pre>
  
  <p>This simple rewrite rule takes any request intended for example2.com and inserts the foo/ to point to the content which is in that directory.  Problem is this keeps doing an external 301 redirect.  I don't want that, I want the browser to stay on example2.com without redirecting while Apache serves up the content from /foo in the filesystem.</p>
  
  <p>Been over the Apache mod_rewrite docs several times, which say how to force a 301 redirect with the [R] flag but don't say how to force it NOT to happen.  What am I missing here?  It is behaving the same on both my Linux shared host and a local test with Apache on Windows.</p>
  
  <p>Thanks!</p>