I have the following site structure:
How can I transfer my project to hosting?
At the same time, in the Open Server, I installed the public folder with the domain folder.

If the root folder for the site files is different from the www folder (public_html) (usually the project files on Laravel are in the public folder), in this case you need to write the following structure in the .htaccess file.
# public_html/.htaccess <IfModule mod_rewrite.c> RewriteEngine on RewriteRule ^$ public/ [L] RewriteRule ((?s).*) public/$1 [L] </IfModule> # public_html/public/.htaccess <IfModule mod_rewrite.c> RewriteEngine On RewriteCond %{REQUEST_FILENAME} !-d RewriteCond %{REQUEST_FILENAME} !-f RewriteRule ^((?s).*)$ index.php?_url=/$1 [QSA,L] </IfModule> The first picture is the structure of your server, and not specifically the site. Your site will be in public_html. It is in public_html that the contents of laravel.loc (C: \ OpenServer \ domains \ laravel.loc) must be placed
.htaccess will not work? - user242433Source: https://ru.stackoverflow.com/questions/695077/
All Articles