Skip to content
Snippets Groups Projects
Commit 308c99f1 authored by Thomas Müller's avatar Thomas Müller
Browse files

Merge pull request #23029 from owncloud/add-rewrite-rules-after-setup

Add base rewrite rule only when RewriteBase is defined
parents 845a45ae bc4a043a
No related branches found
No related tags found
No related merge requests found
......@@ -65,7 +65,6 @@
RewriteCond %{REQUEST_FILENAME} !/updater/
RewriteCond %{REQUEST_FILENAME} !/ocs-provider/
RewriteCond %{REQUEST_URI} !^/.well-known/acme-challenge/.*
RewriteRule .* index.php [PT,E=PATH_INFO:$1]
</IfModule>
<IfModule mod_mime.c>
AddType image/svg+xml svg svgz
......
......@@ -422,8 +422,9 @@ class Setup {
// Add rewrite base
$webRoot = !empty(\OC::$WEBROOT) ? \OC::$WEBROOT : '/';
$content.="\n<IfModule mod_rewrite.c>";
$content.="\n RewriteBase ".$webRoot;
$content .= "\n<IfModule mod_rewrite.c>";
$content .= "\n RewriteRule .* index.php [PT,E=PATH_INFO:$1]";
$content .= "\n RewriteBase ".$webRoot;
$content .= "\n <IfModule mod_env.c>";
$content .= "\n SetEnv front_controller_active true";
$content .= "\n <IfModule mod_dir.c>";
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment