From 82bd94cefe6c451a540e3d25ff4ba1613d2d6408 Mon Sep 17 00:00:00 2001 From: Egorka Date: Tue, 4 Sep 2018 23:14:28 +0300 Subject: [PATCH] Installer fix modules and apache static htaccess --- setup.php | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/setup.php b/setup.php index 478a478..0d71c7a 100644 --- a/setup.php +++ b/setup.php @@ -296,9 +296,6 @@ $main_htacces = <<_domain} RewriteRule ^(.*)$ zxcms/static/$1 [L] - #RewriteCond %{HTTP_HOST} ^static.{$this->_domain} - #RewriteRule ^(.*)$ $1 [L] - RewriteCond %{HTTP_HOST} ^admin.{$this->_domain} RewriteRule ^(.*)$ zxcms/backend/web/$1 [L] @@ -316,7 +313,6 @@ $main_htacces = <<_domain} RewriteRule ^.*$ zxcms/backend/web/index.php [L] - #RewriteCond %{REQUEST_URI} !^/zxcms/static RewriteCond %{REQUEST_URI} ^/(assets|css|js|images) RewriteRule ^assets/(.*)$ zxcms/frontend/web/assets/$1 [L] RewriteRule ^css/(.*)$ zxcms/frontend/web/css/$1 [L] @@ -324,7 +320,6 @@ $main_htacces = <<_http_protocol}://{$this->_domain}/site/error [R=404,L] ErrorDocument 404 {$this->_http_protocol}://{$this->_domain}/site/error SH; - file_put_contents(__DIR__ . '/frontend/web/.htaccess', $static_htaccess); + file_put_contents(__DIR__ . '/static/.htaccess', $static_htaccess); } private function addPermissions() : void @@ -386,7 +381,7 @@ SH; 'languages', 'pages', 'forms', 'links' ]; foreach ($systemModules as $name) { - shell_exec('php ' . __DIR__ . '/yii module/add "' . $name . '"'); + shell_exec('php ' . __DIR__ . '/yii module/activate "' . $name . '"'); } echo Console::log($this->l('Complete'), 'green') . PHP_EOL; }