[BUGFIX] Correct path for redirect to Installer 73/38973/3
authorMarkus Klein <klein.t3@reelworx.at>
Mon, 27 Apr 2015 19:49:39 +0000 (21:49 +0200)
committerChristian Kuhn <lolli@schwarzbu.ch>
Mon, 27 Apr 2015 22:00:06 +0000 (00:00 +0200)
Resolves: #66615
Releases: master
Change-Id: Ia8497f963b8e4189df1e43b93624db57bedf0e54
Reviewed-on: http://review.typo3.org/38973
Reviewed-by: Stephan Großberndt <stephan@grossberndt.de>
Reviewed-by: Frank Nägler <typo3@naegler.net>
Tested-by: Frank Nägler <typo3@naegler.net>
Reviewed-by: Christian Kuhn <lolli@schwarzbu.ch>
Tested-by: Christian Kuhn <lolli@schwarzbu.ch>
typo3/sysext/core/Classes/Core/Bootstrap.php

index 7db53a3..d52f84c 100644 (file)
@@ -174,11 +174,7 @@ class Bootstrap {
                                ->loadConfigurationAndInitialize(FALSE, \TYPO3\CMS\Core\Package\FailsafePackageManager::class);
                } elseif (!$this->checkIfEssentialConfigurationExists() && !defined('TYPO3_cliMode')) {
                        // Redirect to install tool if base configuration is not found
-                       $backPathToSiteRoot = '';
-                       $pathParts = explode('/', $relativePathPart);
-                       for ($i = 1; $i <= count($pathParts); $i++) {
-                               $backPathToSiteRoot .= '../';
-                       }
+                       $backPathToSiteRoot = str_repeat('../', count(explode('/', $relativePathPart)) - 1);
                        $this->redirectToInstallTool($backPathToSiteRoot);
                } else {
                        // Regular request (Frontend, AJAX, Backend, CLI)