Skip to content
This repository was archived by the owner on Jan 1, 2020. It is now read-only.

Commit f4b02c3

Browse files
committed
Merge pull request #263 from contributed/patch-1
Fix RewriteRule for subdirectory installation
2 parents 70b2ab6 + 5647699 commit f4b02c3

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

public/.htaccess

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,13 @@ RewriteEngine On
44
RewriteCond %{REQUEST_FILENAME} -s [OR]
55
RewriteCond %{REQUEST_FILENAME} -l [OR]
66
RewriteCond %{REQUEST_FILENAME} -d
7-
RewriteRule ^.*$ - [NC,L]
7+
RewriteRule ^.*$ - [L]
88
# The following rewrites all other queries to index.php. The
99
# condition ensures that if you are using Apache aliases to do
10-
# mass virtual hosting, the base path will be prepended to
11-
# allow proper resolution of the index.php file; it will work
12-
# in non-aliased environments as well, providing a safe, one-size
13-
# fits all solution.
14-
RewriteCond %{REQUEST_URI}::$1 ^(/.+)(.+)::\2$
10+
# mass virtual hosting or installed the project in a subdirectory,
11+
# the base path will be prepended to allow proper resolution of
12+
# the index.php file; it will work in non-aliased environments
13+
# as well, providing a safe, one-size fits all solution.
14+
RewriteCond %{REQUEST_URI}::$1 ^(/.+)/(.*)::\2$
1515
RewriteRule ^(.*) - [E=BASE:%1]
16-
RewriteRule ^(.*)$ %{ENV:BASE}index.php [NC,L]
16+
RewriteRule ^(.*)$ %{ENV:BASE}/index.php [L]

0 commit comments

Comments
 (0)