title: Use htaccess to redirect subdomain to folder with Laravel
body: <p>I have my websites on a remote server, which I cannot access so my only way is using .htaccess files.</p>
  
  <p>The directory structure looks like this:</p>
  
  <pre><code>/public_html/
  └── _sub/
  │    └── abc/
  ├── folder1/
  ├── folder2/
  └── folder3/
  </code></pre>
  
  <p>Which generates a subdomain abc.domain.com., other folders are accessible from www.domain.com/folder1, etc. Now I copied Laravel 5 to the /_sub/abc/ folder, so I can access it with abc.domain.com/public. But I need to access the Laravel without /public/ in the URL with all the routes working. I tried couple of examples in here but they failed to work with the routes like abc.domain.com/auth/login</p>
  
  <p>htaccess in the public is the Laravel 5 default:</p>
  
  <pre><code>&lt;IfModule mod_rewrite.c&gt;
  &lt;IfModule mod_negotiation.c&gt;
      Options -MultiViews
  &lt;/IfModule&gt;
  
  RewriteEngine On
  
  # Redirect Trailing Slashes If Not A Folder...
  RewriteCond %{REQUEST_FILENAME} !-d
  RewriteRule ^(.*)/$ /$1 [L,R=301]
  
  # Handle Front Controller...
  RewriteCond %{REQUEST_FILENAME} !-d
  RewriteCond %{REQUEST_FILENAME} !-f
  RewriteRule ^ index.php [L]
  </code></pre>
  
  <p></p>
  
  <p>Thanks for any help.</p>