title: Disable access to addon domain through maindomain.com/addondomainfolder
body: <p>I want to disable access to the folder of my addon domain using .htaccess but I can't seem to figure it out.</p>
  
  <p>My folder structure is like this:</p>
  
  <pre><code>root/maindomain (www.maindomain.com/maindomain)
  root/addondomain (www.addondomain.com)
  </code></pre>
  
  <p>I want to disable access to my addon domain through the <em>www.maindomain.com/addondomain</em> url.</p>
  
  <p>How would I do this?</p>
  
  <p>My htaccess file in the root directory:</p>
  
  <pre><code>RewriteEngine On
  RewriteCond %{HTTP_HOST} ^(www\.)?swen\.me.uk$ [NC]
  RewriteRule ^/?creepypastaindex http://www.creepypastaindex.com/ [L,R]
  
  RewriteEngine On
  RewriteCond %{HTTP_HOST} ^(www\.)?swen.me.uk$
  RewriteCond %{REQUEST_URI} !^/swen/
  RewriteRule ^(.*)$ /swen/$1
  </code></pre>