title: 301 redirect non-www in subfolder via .htaccess
body: <p>I'm trying to redirect all non-www pages to a www page on my site using the .htaccess file. It's a multilingual site and it's set up with a site in the root folder in danish, and an English version in www.domain.com/en/.</p>
  
  <p>I got the non-www redirect working on the danish part but I'm having problems in the english subfolder. Each folder has it's own .htaccess.</p>
  
  <p>On the danish end my request looks like this: </p>
  
  <pre><code>#301 redirect #RewriteEngine On
  
  RewriteCond %{HTTP_HOST} ^example\.com$
  RewriteRule ^(.*) http://www.example.com/$1 [R=301] 
  </code></pre>
  
  <p>And I'm thinking that the English equivalent should look like this:</p>
  
  <pre><code>#RewriteEngine On
  
  RewriteCond %{HTTP_HOST} ^example\.com/en/$
  RewriteRule ^(.*) http://www.example.com/en/$1 [R=301] 
  </code></pre>
  
  <p>I would really appreciate any help I can get.</p>