This commit is contained in:
parent
03bc35afe1
commit
aef6c0d440
26
.htaccess
26
.htaccess
@ -1,32 +1,24 @@
|
|||||||
<IfModule mod_rewrite.c>
|
<IfModule mod_rewrite.c>
|
||||||
<IfModule mod_negotiation.c>
|
Options -MultiViews -Indexes
|
||||||
Options -MultiViews -Indexes
|
|
||||||
</IfModule>
|
|
||||||
|
|
||||||
RewriteEngine On
|
RewriteEngine On
|
||||||
|
|
||||||
# Preserve Authorization header for API/auth
|
|
||||||
RewriteCond %{HTTP:Authorization} .
|
|
||||||
RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}]
|
|
||||||
|
|
||||||
# Redirect any requests for /home/... static files into the public/home folder
|
RewriteRule ^home/(.+\.(?:css|js|png|jpe?g|gif|svg|ico|woff2?|ttf|eot|otf|webp))$ public/home/$1 [L]
|
||||||
RewriteCond %{REQUEST_URI} !^/public/
|
|
||||||
RewriteCond %{REQUEST_URI} ^/home/.*\.(css|js|png|jpe?g|gif|svg|ico|woff2?|ttf|eot|otf|webp)$ [NC]
|
|
||||||
RewriteRule ^(.*)$ public/$1 [L]
|
|
||||||
|
|
||||||
# Serve existing files and directories directly
|
|
||||||
RewriteCond %{REQUEST_FILENAME} -f [OR]
|
RewriteCond %{REQUEST_FILENAME} -f [OR]
|
||||||
RewriteCond %{REQUEST_FILENAME} -d
|
RewriteCond %{REQUEST_FILENAME} -d
|
||||||
RewriteRule ^ - [L]
|
RewriteRule ^ - [L]
|
||||||
|
|
||||||
# Remove trailing slashes for non-directories
|
|
||||||
RewriteCond %{REQUEST_FILENAME} !-d
|
|
||||||
RewriteRule ^(.+)/$ /$1 [L,R=301]
|
|
||||||
|
|
||||||
# All other requests go to Laravel's front controller
|
RewriteCond %{REQUEST_FILENAME} !-d
|
||||||
|
RewriteRule ^(.+)/$ /$1 [R=301,L]
|
||||||
|
|
||||||
|
|
||||||
RewriteRule ^ index.php [L]
|
RewriteRule ^ index.php [L]
|
||||||
</IfModule>
|
</IfModule>
|
||||||
|
|
||||||
<FilesMatch "\.(php4|php5|php3|php2|php|phtml)$">
|
<FilesMatch "\.php$">
|
||||||
|
# ensure LSAPI for PHP
|
||||||
SetHandler application/x-lsphp81
|
SetHandler application/x-lsphp81
|
||||||
</FilesMatch>
|
</FilesMatch>
|
||||||
|
@ -1,32 +1,15 @@
|
|||||||
<IfModule mod_rewrite.c>
|
<IfModule mod_rewrite.c>
|
||||||
<IfModule mod_negotiation.c>
|
Options -MultiViews -Indexes
|
||||||
Options -MultiViews -Indexes
|
|
||||||
</IfModule>
|
|
||||||
|
|
||||||
RewriteEngine On
|
RewriteEngine On
|
||||||
|
|
||||||
# Preserve Authorization header for API/auth
|
# If the file or folder exists, serve it
|
||||||
RewriteCond %{HTTP:Authorization} .
|
RewriteCond %{REQUEST_FILENAME} !-f
|
||||||
RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}]
|
|
||||||
|
|
||||||
# Redirect any requests for /home/... static files into the public/home folder
|
|
||||||
RewriteCond %{REQUEST_URI} !^/public/
|
|
||||||
RewriteCond %{REQUEST_URI} ^/home/.*\.(css|js|png|jpe?g|gif|svg|ico|woff2?|ttf|eot|otf|webp)$ [NC]
|
|
||||||
RewriteRule ^(.*)$ public/$1 [L]
|
|
||||||
|
|
||||||
# Serve existing files and directories directly
|
|
||||||
RewriteCond %{REQUEST_FILENAME} -f [OR]
|
|
||||||
RewriteCond %{REQUEST_FILENAME} -d
|
|
||||||
RewriteRule ^ - [L]
|
|
||||||
|
|
||||||
# Remove trailing slashes for non-directories
|
|
||||||
RewriteCond %{REQUEST_FILENAME} !-d
|
RewriteCond %{REQUEST_FILENAME} !-d
|
||||||
RewriteRule ^(.+)/$ /$1 [L,R=301]
|
|
||||||
|
|
||||||
# All other requests go to Laravel's front controller
|
# Otherwise rewrite to index.php
|
||||||
RewriteRule ^ index.php [L]
|
RewriteRule ^ index.php [L]
|
||||||
</IfModule>
|
</IfModule>
|
||||||
|
|
||||||
<FilesMatch "\.(php4|php5|php3|php2|php|phtml)$">
|
<FilesMatch "\.php$">
|
||||||
SetHandler application/x-lsphp81
|
SetHandler application/x-lsphp81
|
||||||
</FilesMatch>
|
</FilesMatch>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user