Last active
May 10, 2019 19:19
-
-
Save thekavish/e606c8236c4077071d6be5db455ce7e0 to your computer and use it in GitHub Desktop.
How to remove /public from Laravel web application
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Add this file in your application root directory | |
<IfModule mod_rewrite.c> | |
RewriteEngine On | |
RewriteCond $1 !^(index\.php|\.well-known) | |
RewriteRule ^(.*)$ public/$1 [L] | |
</IfModule> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
With this method you do not need to modify any default file structure of the app.
Add this file into your application directory (outside
public/
folder).