diff --git a/typo3/sysext/core/Classes/Configuration/ConfigurationManager.php b/typo3/sysext/core/Classes/Configuration/ConfigurationManager.php index 7333f4d9d648ecf17893b77a7fb4eb41855ad954..4f3cc11d6e7ced9945afee64f569121fb0e1f0e7 100644 --- a/typo3/sysext/core/Classes/Configuration/ConfigurationManager.php +++ b/typo3/sysext/core/Classes/Configuration/ConfigurationManager.php @@ -1,6 +1,5 @@ <?php namespace TYPO3\CMS\Core\Configuration; -use TYPO3\CMS\Core\Utility; /*************************************************************** * Copyright notice @@ -24,6 +23,9 @@ use TYPO3\CMS\Core\Utility; * * This copyright notice MUST APPEAR in all copies of the script! ***************************************************************/ + +use TYPO3\CMS\Core\Utility; + /** * Handle loading and writing of global and local (instance specific) * configuration. @@ -78,7 +80,8 @@ class ConfigurationManager { 'EXT/extConf', 'EXTCONF', 'INSTALL/wizardDone', - 'DB' + 'DB', + 'SYS/caching/cacheConfigurations', ); /** diff --git a/typo3/sysext/core/Configuration/DefaultConfiguration.php b/typo3/sysext/core/Configuration/DefaultConfiguration.php index 601c93c4e356bd62d7f19b36eb4498d2ca0d6aa2..2970f68fa281e0ca840a0076b8bffb0a781226d2 100644 --- a/typo3/sysext/core/Configuration/DefaultConfiguration.php +++ b/typo3/sysext/core/Configuration/DefaultConfiguration.php @@ -21,6 +21,7 @@ * * This copyright notice MUST APPEAR in all copies of the script! ***************************************************************/ + /** * This file contains the default array definition that is * later populated as $GLOBALS['TYPO3_CONF_VARS'] @@ -756,4 +757,4 @@ return array( ), 'SVCONF' => array() ); -?> \ No newline at end of file +?> diff --git a/typo3/sysext/install/Classes/Configuration/AbstractCustomPreset.php b/typo3/sysext/install/Classes/Configuration/AbstractCustomPreset.php new file mode 100644 index 0000000000000000000000000000000000000000..21629a4b72cc7dba8f389da695bc1cb4ff4961d3 --- /dev/null +++ b/typo3/sysext/install/Classes/Configuration/AbstractCustomPreset.php @@ -0,0 +1,104 @@ +<?php +namespace TYPO3\CMS\Install\Configuration; + +/*************************************************************** + * Copyright notice + * + * (c) 2013 Christian Kuhn <lolli@schwarzbu.ch> + * All rights reserved + * + * This script is part of the TYPO3 project. The TYPO3 project is + * free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * The GNU General Public License can be found at + * http://www.gnu.org/copyleft/gpl.html. + * + * This script is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * This copyright notice MUST APPEAR in all copies of the script! + ***************************************************************/ + +use TYPO3\CMS\Core\Utility\GeneralUtility; + +/** + * Abstract custom preset class implements common preset code + */ +abstract class AbstractCustomPreset extends AbstractPreset { + + /** + * @var string Name of preset, always set to "Custom" + */ + protected $name = 'Custom'; + + /** + * @var boolean TRUE if custom preset is active + */ + protected $isActive = FALSE; + + /** + * @var integer Priority of custom prefix is usually the lowest + */ + protected $priority = 10; + + /** + * Whether custom preset is active is set by feature + * + * @return boolean TRUE if custom preset is active + */ + public function isActive() { + return $this->isActive; + } + + /** + * Mark preset as active. + * The custom features do not know by itself if they are + * active or not since the configuration options may overlay + * with other presets. + * Marking the custom preset as active is therefor taken care + * off by the feature itself if no other preset is active. + * + * @return void + */ + public function setActive() { + $this->isActive = TRUE; + } + + /** + * Custom configuration is always available + * + * @return boolean TRUE + */ + public function isAvailable() { + return TRUE; + } + + /** + * Get configuration values is used in fluid to show configuration options. + * They are fetched from LocalConfiguration / DefaultConfiguration and + * merged with given $postValues. + * + * @return array Configuration values needed to activate prefix + */ + public function getConfigurationValues() { + $configurationValues = array(); + foreach ($this->configurationValues as $configurationKey => $configurationValue) { + if (isset($this->postValues['enable']) + && $this->postValues['enable'] === $this->name + && isset($this->postValues[$this->name][$configurationKey]) + ) { + $currentValue = $this->postValues[$this->name][$configurationKey]; + } else { + $currentValue = $this->configurationManager->getConfigurationValueByPath($configurationKey); + } + $configurationValues[$configurationKey] = $currentValue; + } + return $configurationValues; + } +} +?> \ No newline at end of file diff --git a/typo3/sysext/install/Classes/Configuration/AbstractFeature.php b/typo3/sysext/install/Classes/Configuration/AbstractFeature.php new file mode 100644 index 0000000000000000000000000000000000000000..5e2ae57060d5e2154a9c9c00d4e44acfe5947b59 --- /dev/null +++ b/typo3/sysext/install/Classes/Configuration/AbstractFeature.php @@ -0,0 +1,143 @@ +<?php +namespace TYPO3\CMS\Install\Configuration; + +/*************************************************************** + * Copyright notice + * + * (c) 2013 Christian Kuhn <lolli@schwarzbu.ch> + * All rights reserved + * + * This script is part of the TYPO3 project. The TYPO3 project is + * free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * The GNU General Public License can be found at + * http://www.gnu.org/copyleft/gpl.html. + * + * This script is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * This copyright notice MUST APPEAR in all copies of the script! + ***************************************************************/ + +/** + * Abstract feature class implements common code + */ +abstract class AbstractFeature { + + /** + * @var \TYPO3\CMS\Extbase\Object\ObjectManager + * @inject + */ + protected $objectManager = NULL; + + /** + * @var string Name of feature + */ + protected $name = ''; + + /** + * @var array List of preset classes + */ + protected $presetRegistry = array(); + + /** + * @var array Holds instances of presets + */ + protected $presetInstances = array(); + + /** + * @var array List of $POST values + */ + protected $postValues = array(); + + /** + * Initialize presets of feature + * + * @param array $postValues List of $POST values of this feature + * @return void + * @throws Exception + */ + public function initializePresets(array $postValues) { + // Give feature sub array of $POST values to preset and set to own property + $featurePostValues = array(); + if (!empty($postValues[$this->name])) { + $featurePostValues = $postValues[$this->name]; + } + $this->postValues = $featurePostValues; + + $isNonCustomPresetActive = FALSE; + $customPresetFound = FALSE; + foreach ($this->presetRegistry as $presetClass) { + /** @var PresetInterface $presetInstance */ + $presetInstance = $this->objectManager->get($presetClass); + if (!($presetInstance instanceof PresetInterface)) { + throw new Exception( + 'Preset ' . $presetClass . ' does not implement PresetInterface', + 1378644821 + ); + } + + $presetInstance->setPostValues($featurePostValues); + + // Custom preset is set active if no preset before is active + if ($presetInstance->isActive()) { + $isNonCustomPresetActive = TRUE; + } + if ($presetInstance instanceof CustomPresetInterface + && !$isNonCustomPresetActive + ) { + // Throw Exception if two custom presets are registered + if ($customPresetFound === TRUE) { + throw new Exception( + 'Preset ' . $presetClass . ' implements CustomPresetInterface, but another' + . ' custom preset is already registered', + 1378645039 + ); + } + + /** @var CustomPresetInterface $presetInstance */ + $presetInstance->setActive(); + $customPresetFound = TRUE; + } + + $this->presetInstances[] = $presetInstance; + } + } + + /** + * Return presets ordered by priority + * + * @return array<PresetInterface> + * @throws Exception + */ + public function getPresetsOrderedByPriority() { + if (empty($this->presetInstances)) { + throw new Exception( + 'Presets not initialized', + 1378645155 + ); + } + $orderedPresets = array(); + foreach ($this->presetInstances as $presetInstance) { + /** @var PresetInterface $presetInstance */ + $orderedPresets[$presetInstance->getPriority()] = $presetInstance; + } + krsort($orderedPresets, SORT_NUMERIC); + return $orderedPresets; + } + + /** + * Return name of feature + * + * @return string Name of feature + */ + public function getName() { + return $this->name; + } +} +?> \ No newline at end of file diff --git a/typo3/sysext/install/Classes/Configuration/AbstractPreset.php b/typo3/sysext/install/Classes/Configuration/AbstractPreset.php new file mode 100644 index 0000000000000000000000000000000000000000..a275a34abb7d414a5faee6683e5f6a657d126f11 --- /dev/null +++ b/typo3/sysext/install/Classes/Configuration/AbstractPreset.php @@ -0,0 +1,143 @@ +<?php +namespace TYPO3\CMS\Install\Configuration; + +/*************************************************************** + * Copyright notice + * + * (c) 2013 Christian Kuhn <lolli@schwarzbu.ch> + * All rights reserved + * + * This script is part of the TYPO3 project. The TYPO3 project is + * free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * The GNU General Public License can be found at + * http://www.gnu.org/copyleft/gpl.html. + * + * This script is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * This copyright notice MUST APPEAR in all copies of the script! + ***************************************************************/ + +use TYPO3\CMS\Core\Utility\GeneralUtility; + +/** + * Abstract preset class implements common preset code + */ +abstract class AbstractPreset { + + /** + * @var \TYPO3\CMS\Core\Configuration\ConfigurationManager + * @inject + */ + protected $configurationManager = NULL; + + /** + * @var string Name of preset, must be set by extending classes + */ + protected $name = ''; + + /** + * @var integer Default priority of preset + */ + protected $priority = 50; + + /** + * @var array Configuration values handled by this preset + */ + protected $configurationValues = array(); + + /** + * @var array List of $POST values + */ + protected $postValues = array(); + + /** + * Set POST values + * + * @param array $postValues Post values of feature + * @return mixed + */ + public function setPostValues(array $postValues) { + $this->postValues = $postValues; + } + + /** + * Check if preset is available on the system + * + * @return boolean TRUE if preset is available + */ + abstract public function isAvailable(); + + /** + * Wrapper for isAvailable, used in fluid + * + * @return boolean TRUE if preset is available + */ + public function getIsAvailable() { + return $this->isAvailable(); + } + + /** + * Check is preset is currently active on the system + * + * @return boolean TRUE if preset is active + */ + public function isActive() { + $isActive = TRUE; + foreach ($this->configurationValues as $configurationKey => $configurationValue) { + try { + $currentValue = $this->configurationManager->getConfigurationValueByPath($configurationKey); + } catch (\RuntimeException $e) { + $currentValue = NULL; + } + if ($currentValue !== $configurationValue) { + $isActive = FALSE; + break; + } + } + return $isActive; + } + + /** + * Wrapper for isActive, used in fluid + * + * @return boolean TRUE if preset is active + */ + public function getIsActive() { + return $this->isActive(); + } + + /** + * Get name of preset + * + * @return string Name + */ + public function getName() { + return $this->name; + } + + /** + * Get priority of preset + * + * @return integer Priority, usually between 0 and 100 + */ + public function getPriority() { + return $this->priority; + } + + /** + * Get configuration values to activate prefix + * + * @return array Configuration values needed to activate prefix + */ + public function getConfigurationValues() { + return $this->configurationValues; + } +} +?> \ No newline at end of file diff --git a/typo3/sysext/install/Classes/Configuration/Charset/CharsetFeature.php b/typo3/sysext/install/Classes/Configuration/Charset/CharsetFeature.php new file mode 100644 index 0000000000000000000000000000000000000000..78ee68025f78c193965958e34cb9c34df7c842b7 --- /dev/null +++ b/typo3/sysext/install/Classes/Configuration/Charset/CharsetFeature.php @@ -0,0 +1,49 @@ +<?php +namespace TYPO3\CMS\Install\Configuration\Charset; + +/*************************************************************** + * Copyright notice + * + * (c) 2013 Christian Kuhn <lolli@schwarzbu.ch> + * All rights reserved + * + * This script is part of the TYPO3 project. The TYPO3 project is + * free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * The GNU General Public License can be found at + * http://www.gnu.org/copyleft/gpl.html. + * + * This script is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * This copyright notice MUST APPEAR in all copies of the script! + ***************************************************************/ + +use TYPO3\CMS\Install\Configuration; + +/** + * Charset conversion feature + */ +class CharsetFeature extends Configuration\AbstractFeature implements Configuration\FeatureInterface { + + /** + * @var string Name of feature + */ + protected $name = 'Charset'; + + /** + * @var array List of preset classes + */ + protected $presetRegistry = array( + 'TYPO3\\CMS\\Install\\Configuration\\Charset\\MbstringPreset', + 'TYPO3\\CMS\\Install\\Configuration\\Charset\\IconvPreset', + 'TYPO3\\CMS\\Install\\Configuration\\Charset\\CoreInternalPreset', + 'TYPO3\\CMS\\Install\\Configuration\\Charset\\CustomPreset', + ); +} +?> \ No newline at end of file diff --git a/typo3/sysext/install/Classes/Configuration/Charset/CoreInternalPreset.php b/typo3/sysext/install/Classes/Configuration/Charset/CoreInternalPreset.php new file mode 100644 index 0000000000000000000000000000000000000000..e18db84f3c0702cfeff95494416179e21a8db6e1 --- /dev/null +++ b/typo3/sysext/install/Classes/Configuration/Charset/CoreInternalPreset.php @@ -0,0 +1,61 @@ +<?php +namespace TYPO3\CMS\Install\Configuration\Charset; + +/*************************************************************** + * Copyright notice + * + * (c) 2013 Christian Kuhn <lolli@schwarzbu.ch> + * All rights reserved + * + * This script is part of the TYPO3 project. The TYPO3 project is + * free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * The GNU General Public License can be found at + * http://www.gnu.org/copyleft/gpl.html. + * + * This script is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * This copyright notice MUST APPEAR in all copies of the script! + ***************************************************************/ + +use TYPO3\CMS\Install\Configuration; + +/** + * Internal core charset handling preset + */ +class CoreInternalPreset extends Configuration\AbstractPreset implements Configuration\PresetInterface { + + /** + * @var string Name of preset + */ + protected $name = 'CoreInternal'; + + /** + * @var integer Priority of preset + */ + protected $priority = 20; + + /** + * @var array Configuration values handled by this preset + */ + protected $configurationValues = array( + 'SYS/t3lib_cs_convMethod' => '', + 'SYS/t3lib_cs_utils' => '', + ); + + /** + * Internal core handling is always available + * + * @return boolean TRUE + */ + public function isAvailable() { + return TRUE; + } +} +?> \ No newline at end of file diff --git a/typo3/sysext/install/Classes/Configuration/Charset/CustomPreset.php b/typo3/sysext/install/Classes/Configuration/Charset/CustomPreset.php new file mode 100644 index 0000000000000000000000000000000000000000..03596073ed5c7b03167e8da26ecf2c9deb74a928 --- /dev/null +++ b/typo3/sysext/install/Classes/Configuration/Charset/CustomPreset.php @@ -0,0 +1,42 @@ +<?php +namespace TYPO3\CMS\Install\Configuration\Charset; + +/*************************************************************** + * Copyright notice + * + * (c) 2013 Christian Kuhn <lolli@schwarzbu.ch> + * All rights reserved + * + * This script is part of the TYPO3 project. The TYPO3 project is + * free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * The GNU General Public License can be found at + * http://www.gnu.org/copyleft/gpl.html. + * + * This script is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * This copyright notice MUST APPEAR in all copies of the script! + ***************************************************************/ + +use TYPO3\CMS\Install\Configuration; + +/** + * Custom preset is a fallback if no other preset fits + */ +class CustomPreset extends Configuration\AbstractCustomPreset implements Configuration\CustomPresetInterface { + + /** + * @var array Configuration values handled by this preset + */ + protected $configurationValues = array( + 'SYS/t3lib_cs_convMethod' => '', + 'SYS/t3lib_cs_utils' => '', + ); +} +?> \ No newline at end of file diff --git a/typo3/sysext/install/Classes/Configuration/Charset/IconvPreset.php b/typo3/sysext/install/Classes/Configuration/Charset/IconvPreset.php new file mode 100644 index 0000000000000000000000000000000000000000..bc45a1a465c353bb18647b21accd05f2d1a049a6 --- /dev/null +++ b/typo3/sysext/install/Classes/Configuration/Charset/IconvPreset.php @@ -0,0 +1,65 @@ +<?php +namespace TYPO3\CMS\Install\Configuration\Charset; + +/*************************************************************** + * Copyright notice + * + * (c) 2013 Christian Kuhn <lolli@schwarzbu.ch> + * All rights reserved + * + * This script is part of the TYPO3 project. The TYPO3 project is + * free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * The GNU General Public License can be found at + * http://www.gnu.org/copyleft/gpl.html. + * + * This script is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * This copyright notice MUST APPEAR in all copies of the script! + ***************************************************************/ + +use TYPO3\CMS\Install\Configuration; + +/** + * Iconv charset preset + */ +class IconvPreset extends Configuration\AbstractPreset implements Configuration\PresetInterface { + + /** + * @var string Name of preset + */ + protected $name = 'Iconv'; + + /** + * @var integer Priority of preset + */ + protected $priority = 80; + + /** + * @var array Configuration values handled by this preset + */ + protected $configurationValues = array( + 'SYS/t3lib_cs_convMethod' => 'iconv', + 'SYS/t3lib_cs_utils' => 'iconv', + ); + + /** + * Check if iconv PHP module is loaded + * + * @return boolean TRUE if iconv PHP module is loaded + */ + public function isAvailable() { + $result = FALSE; + if (extension_loaded('iconv')) { + $result = TRUE; + } + return $result; + } +} +?> \ No newline at end of file diff --git a/typo3/sysext/install/Classes/Configuration/Charset/MbstringPreset.php b/typo3/sysext/install/Classes/Configuration/Charset/MbstringPreset.php new file mode 100644 index 0000000000000000000000000000000000000000..678ebf9fb393456f8c5fce70f140c546939d39b7 --- /dev/null +++ b/typo3/sysext/install/Classes/Configuration/Charset/MbstringPreset.php @@ -0,0 +1,65 @@ +<?php +namespace TYPO3\CMS\Install\Configuration\Charset; + +/*************************************************************** + * Copyright notice + * + * (c) 2013 Christian Kuhn <lolli@schwarzbu.ch> + * All rights reserved + * + * This script is part of the TYPO3 project. The TYPO3 project is + * free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * The GNU General Public License can be found at + * http://www.gnu.org/copyleft/gpl.html. + * + * This script is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * This copyright notice MUST APPEAR in all copies of the script! + ***************************************************************/ + +use TYPO3\CMS\Install\Configuration; + +/** + * Mbstring charset preset + */ +class MbstringPreset extends Configuration\AbstractPreset implements Configuration\PresetInterface { + + /** + * @var string Name of preset + */ + protected $name = 'Mbstring'; + + /** + * @var integer Priority of preset + */ + protected $priority = 90; + + /** + * @var array Configuration values handled by this preset + */ + protected $configurationValues = array( + 'SYS/t3lib_cs_convMethod' => 'mbstring', + 'SYS/t3lib_cs_utils' => 'mbstring', + ); + + /** + * Check if mbstring PHP module is loaded + * + * @return boolean TRUE if mbstring PHP module is loaded + */ + public function isAvailable() { + $result = FALSE; + if (extension_loaded('mbstring')) { + $result = TRUE; + } + return $result; + } +} +?> \ No newline at end of file diff --git a/typo3/sysext/install/Classes/Configuration/Context/ContextFeature.php b/typo3/sysext/install/Classes/Configuration/Context/ContextFeature.php new file mode 100644 index 0000000000000000000000000000000000000000..9745883d0141c01fa21b9b8553ef1baf7df69a6c --- /dev/null +++ b/typo3/sysext/install/Classes/Configuration/Context/ContextFeature.php @@ -0,0 +1,48 @@ +<?php +namespace TYPO3\CMS\Install\Configuration\Context; + +/*************************************************************** + * Copyright notice + * + * (c) 2013 Christian Kuhn <lolli@schwarzbu.ch> + * All rights reserved + * + * This script is part of the TYPO3 project. The TYPO3 project is + * free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * The GNU General Public License can be found at + * http://www.gnu.org/copyleft/gpl.html. + * + * This script is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * This copyright notice MUST APPEAR in all copies of the script! + ***************************************************************/ + +use TYPO3\CMS\Install\Configuration; + +/** + * Context feature sets development / production settings + */ +class ContextFeature extends Configuration\AbstractFeature implements Configuration\FeatureInterface { + + /** + * @var string Name of feature + */ + protected $name = 'Context'; + + /** + * @var array List of preset classes + */ + protected $presetRegistry = array( + 'TYPO3\\CMS\\Install\\Configuration\\Context\\ProductionPreset', + 'TYPO3\\CMS\\Install\\Configuration\\Context\\DevelopmentPreset', + 'TYPO3\\CMS\\Install\\Configuration\\Context\\CustomPreset', + ); +} +?> \ No newline at end of file diff --git a/typo3/sysext/install/Classes/Configuration/Context/CustomPreset.php b/typo3/sysext/install/Classes/Configuration/Context/CustomPreset.php new file mode 100644 index 0000000000000000000000000000000000000000..a8fad1d0e466a9b89dbfc0592a4558e9671ac22a --- /dev/null +++ b/typo3/sysext/install/Classes/Configuration/Context/CustomPreset.php @@ -0,0 +1,47 @@ +<?php +namespace TYPO3\CMS\Install\Configuration\Context; + +/*************************************************************** + * Copyright notice + * + * (c) 2013 Christian Kuhn <lolli@schwarzbu.ch> + * All rights reserved + * + * This script is part of the TYPO3 project. The TYPO3 project is + * free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * The GNU General Public License can be found at + * http://www.gnu.org/copyleft/gpl.html. + * + * This script is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * This copyright notice MUST APPEAR in all copies of the script! + ***************************************************************/ + +use TYPO3\CMS\Install\Configuration; + +/** + * Custom preset is a fallback if no other preset fits + */ +class CustomPreset extends Configuration\AbstractCustomPreset implements Configuration\CustomPresetInterface { + + /** + * @var array Configuration values handled by this preset + */ + protected $configurationValues = array( + 'BE/debug' => '', + 'FE/debug' => '', + 'SYS/devIPmask' => '', + 'SYS/displayErrors' => '', + 'SYS/enableDeprecationLog' => '', + 'SYS/sqlDebug' => '', + 'SYS/systemLogLevel' => '', + ); +} +?> \ No newline at end of file diff --git a/typo3/sysext/install/Classes/Configuration/Context/DevelopmentPreset.php b/typo3/sysext/install/Classes/Configuration/Context/DevelopmentPreset.php new file mode 100644 index 0000000000000000000000000000000000000000..09e18356102e1edcd0c936f6159301e00d33231b --- /dev/null +++ b/typo3/sysext/install/Classes/Configuration/Context/DevelopmentPreset.php @@ -0,0 +1,81 @@ +<?php +namespace TYPO3\CMS\Install\Configuration\Context; + +/*************************************************************** + * Copyright notice + * + * (c) 2013 Christian Kuhn <lolli@schwarzbu.ch> + * All rights reserved + * + * This script is part of the TYPO3 project. The TYPO3 project is + * free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * The GNU General Public License can be found at + * http://www.gnu.org/copyleft/gpl.html. + * + * This script is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * This copyright notice MUST APPEAR in all copies of the script! + ***************************************************************/ + +use TYPO3\CMS\Install\Configuration; + +/** + * Development preset + */ +class DevelopmentPreset extends Configuration\AbstractPreset implements Configuration\PresetInterface { + + /** + * @var string Name of preset + */ + protected $name = 'Development'; + + /** + * @var integer Priority of preset + */ + protected $priority = 50; + + /** + * @var array Configuration values handled by this preset + */ + protected $configurationValues = array( + 'BE/debug' => TRUE, + 'FE/debug' => TRUE, + 'SYS/devIPmask' => '*', + 'SYS/displayErrors' => TRUE, + 'SYS/enableDeprecationLog' => 'file', + 'SYS/sqlDebug' => 1, + 'SYS/systemLogLevel' => 0, + ); + + /** + * Production preset is always available + * + * @return boolean TRUE if mbstring PHP module is loaded + */ + public function isAvailable() { + return TRUE; + } + + /** + * If context is set to production, priority + * of this preset is raised. + * + * @return integer Priority of preset + */ + public function getPriority() { + $context = \TYPO3\CMS\Core\Utility\GeneralUtility::getContext(); + $priority = $this->priority; + if ($context->isDevelopment()) { + $priority = $priority + 20; + } + return $priority; + } +} +?> \ No newline at end of file diff --git a/typo3/sysext/install/Classes/Configuration/Context/ProductionPreset.php b/typo3/sysext/install/Classes/Configuration/Context/ProductionPreset.php new file mode 100644 index 0000000000000000000000000000000000000000..8a4c66e0dabdce40392c9a18367a09bcf7be3bab --- /dev/null +++ b/typo3/sysext/install/Classes/Configuration/Context/ProductionPreset.php @@ -0,0 +1,81 @@ +<?php +namespace TYPO3\CMS\Install\Configuration\Context; + +/*************************************************************** + * Copyright notice + * + * (c) 2013 Christian Kuhn <lolli@schwarzbu.ch> + * All rights reserved + * + * This script is part of the TYPO3 project. The TYPO3 project is + * free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * The GNU General Public License can be found at + * http://www.gnu.org/copyleft/gpl.html. + * + * This script is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * This copyright notice MUST APPEAR in all copies of the script! + ***************************************************************/ + +use TYPO3\CMS\Install\Configuration; + +/** + * Production preset + */ +class ProductionPreset extends Configuration\AbstractPreset implements Configuration\PresetInterface { + + /** + * @var string Name of preset + */ + protected $name = 'Production'; + + /** + * @var integer Priority of preset + */ + protected $priority = 50; + + /** + * @var array Configuration values handled by this preset + */ + protected $configurationValues = array( + 'BE/debug' => FALSE, + 'FE/debug' => FALSE, + 'SYS/devIPmask' => '', + 'SYS/displayErrors' => FALSE, + 'SYS/enableDeprecationLog' => FALSE, + 'SYS/sqlDebug' => 0, + 'SYS/systemLogLevel' => 2, + ); + + /** + * Production preset is always available + * + * @return boolean TRUE if mbstring PHP module is loaded + */ + public function isAvailable() { + return TRUE; + } + + /** + * If context is set to production, priority + * of this preset is raised. + * + * @return integer Priority of preset + */ + public function getPriority() { + $context = \TYPO3\CMS\Core\Utility\GeneralUtility::getContext(); + $priority = $this->priority; + if ($context->isProduction()) { + $priority = $priority + 20; + } + return $priority; + } +} +?> \ No newline at end of file diff --git a/typo3/sysext/install/Classes/Configuration/CustomPresetInterface.php b/typo3/sysext/install/Classes/Configuration/CustomPresetInterface.php new file mode 100644 index 0000000000000000000000000000000000000000..78b27b9f588bb0f7b5161c83623e163ac6be6c27 --- /dev/null +++ b/typo3/sysext/install/Classes/Configuration/CustomPresetInterface.php @@ -0,0 +1,51 @@ +<?php +namespace TYPO3\CMS\Install\Configuration; + +/*************************************************************** + * Copyright notice + * + * (c) 2013 Christian Kuhn <lolli@schwarzbu.ch> + * All rights reserved + * + * This script is part of the TYPO3 project. The TYPO3 project is + * free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * The GNU General Public License can be found at + * http://www.gnu.org/copyleft/gpl.html. + * + * This script is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * This copyright notice MUST APPEAR in all copies of the script! + ***************************************************************/ + +use TYPO3\CMS\Core\Utility\GeneralUtility; + +/** + * Custom preset interface + * + * Interface for presets not catched by other presets. + * Represents "custom" configuration options of a feature. + * + * There must be only one custom preset per feature! + */ +interface CustomPresetInterface extends PresetInterface { + + /** + * Mark preset as active. + * The custom features do not know by itself if they are + * active or not since the configuration options may overlay + * with other presets. + * Marking the custom preset as active is therefor taken care + * off by the feature itself if no other preset is active. + * + * @return void + */ + public function setActive(); +} +?> \ No newline at end of file diff --git a/typo3/sysext/install/Classes/Configuration/Exception.php b/typo3/sysext/install/Classes/Configuration/Exception.php new file mode 100644 index 0000000000000000000000000000000000000000..4328305a0eb3bbd32b2bbbed422e25be1f733b8a --- /dev/null +++ b/typo3/sysext/install/Classes/Configuration/Exception.php @@ -0,0 +1,33 @@ +<?php +namespace TYPO3\CMS\Install\Configuration; + +/*************************************************************** + * Copyright notice + * + * (c) 2013 Christian Kuhn <lolli@schwarzbu.ch> + * All rights reserved + * + * This script is part of the TYPO3 project. The TYPO3 project is + * free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * The GNU General Public License can be found at + * http://www.gnu.org/copyleft/gpl.html. + * + * This script is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * This copyright notice MUST APPEAR in all copies of the script! + ***************************************************************/ + +/** + * A configuration exception + */ +class Exception extends \TYPO3\CMS\Install\Exception { + +} +?> \ No newline at end of file diff --git a/typo3/sysext/install/Classes/Configuration/ExtbaseObjectCache/ApcPreset.php b/typo3/sysext/install/Classes/Configuration/ExtbaseObjectCache/ApcPreset.php new file mode 100644 index 0000000000000000000000000000000000000000..0b462ebe7bf6da292c61dc19416812193855986b --- /dev/null +++ b/typo3/sysext/install/Classes/Configuration/ExtbaseObjectCache/ApcPreset.php @@ -0,0 +1,75 @@ +<?php +namespace TYPO3\CMS\Install\Configuration\ExtbaseObjectCache; + +/*************************************************************** + * Copyright notice + * + * (c) 2013 Christian Kuhn <lolli@schwarzbu.ch> + * All rights reserved + * + * This script is part of the TYPO3 project. The TYPO3 project is + * free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * The GNU General Public License can be found at + * http://www.gnu.org/copyleft/gpl.html. + * + * This script is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * This copyright notice MUST APPEAR in all copies of the script! + ***************************************************************/ + +use TYPO3\CMS\Install\Configuration; + +/** + * APC preset + */ +class ApcPreset extends Configuration\AbstractPreset implements Configuration\PresetInterface { + + /** + * @var string Name of preset + */ + protected $name = 'Apc'; + + /** + * @var integer Priority of preset + */ + protected $priority = 80; + + /** + * @var array Configuration values handled by this preset + */ + protected $configurationValues = array( + 'SYS/caching/cacheConfigurations/extbase_object' => array( + 'backend' => 'TYPO3\CMS\Core\Cache\Backend\ApcBackend', + ), + ); + + /** + * APC preset is available if extension is loaded, if APC has ~100MB + * memory and if ~5MB are free. + * + * @return boolean TRUE + */ + public function isAvailable() { + $result = FALSE; + if (extension_loaded('apc')) { + $memoryInfo = apc_sma_info(); + $totalMemory = $memoryInfo['num_seg'] * $memoryInfo['seg_size']; + $availableMemory = $memoryInfo['avail_mem']; + + // If more than 99MB in total and more than 5MB free + if ($totalMemory > (99 * 1024 * 1024) + && $availableMemory > (5 * 1024 * 1024)) { + $result = TRUE; + } + } + return $result; + } +} +?> \ No newline at end of file diff --git a/typo3/sysext/install/Classes/Configuration/ExtbaseObjectCache/DatabasePreset.php b/typo3/sysext/install/Classes/Configuration/ExtbaseObjectCache/DatabasePreset.php new file mode 100644 index 0000000000000000000000000000000000000000..07583a2529ca6e44335cce41c5de9c38bc21a884 --- /dev/null +++ b/typo3/sysext/install/Classes/Configuration/ExtbaseObjectCache/DatabasePreset.php @@ -0,0 +1,60 @@ +<?php +namespace TYPO3\CMS\Install\Configuration\ExtbaseObjectCache; + +/*************************************************************** + * Copyright notice + * + * (c) 2013 Christian Kuhn <lolli@schwarzbu.ch> + * All rights reserved + * + * This script is part of the TYPO3 project. The TYPO3 project is + * free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * The GNU General Public License can be found at + * http://www.gnu.org/copyleft/gpl.html. + * + * This script is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * This copyright notice MUST APPEAR in all copies of the script! + ***************************************************************/ + +use TYPO3\CMS\Install\Configuration; + +/** + * Database preset + */ +class DatabasePreset extends Configuration\AbstractPreset implements Configuration\PresetInterface { + + /** + * @var string Name of preset + */ + protected $name = 'Database'; + + /** + * @var integer Priority of preset + */ + protected $priority = 50; + + /** + * @var array Configuration values handled by this preset + */ + protected $configurationValues = array( + 'SYS/caching/cacheConfigurations/extbase_object' => array(), + ); + + /** + * Database preset is always available + * + * @return boolean TRUE + */ + public function isAvailable() { + return TRUE; + } +} +?> \ No newline at end of file diff --git a/typo3/sysext/install/Classes/Configuration/ExtbaseObjectCache/ExtbaseObjectCacheFeature.php b/typo3/sysext/install/Classes/Configuration/ExtbaseObjectCache/ExtbaseObjectCacheFeature.php new file mode 100644 index 0000000000000000000000000000000000000000..f1515a48656487eafa3f4b1500fbf7593a4dc22a --- /dev/null +++ b/typo3/sysext/install/Classes/Configuration/ExtbaseObjectCache/ExtbaseObjectCacheFeature.php @@ -0,0 +1,47 @@ +<?php +namespace TYPO3\CMS\Install\Configuration\ExtbaseObjectCache; + +/*************************************************************** + * Copyright notice + * + * (c) 2013 Christian Kuhn <lolli@schwarzbu.ch> + * All rights reserved + * + * This script is part of the TYPO3 project. The TYPO3 project is + * free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * The GNU General Public License can be found at + * http://www.gnu.org/copyleft/gpl.html. + * + * This script is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * This copyright notice MUST APPEAR in all copies of the script! + ***************************************************************/ + +use TYPO3\CMS\Install\Configuration; + +/** + * Extbase object cache configuration + */ +class ExtbaseObjectCacheFeature extends Configuration\AbstractFeature implements Configuration\FeatureInterface { + + /** + * @var string Name of feature + */ + protected $name = 'ExtbaseObjectCache'; + + /** + * @var array List of preset classes + */ + protected $presetRegistry = array( + 'TYPO3\\CMS\\Install\\Configuration\\ExtbaseObjectCache\\DatabasePreset', + 'TYPO3\\CMS\\Install\\Configuration\\ExtbaseObjectCache\\ApcPreset', + ); +} +?> \ No newline at end of file diff --git a/typo3/sysext/install/Classes/Configuration/FeatureInterface.php b/typo3/sysext/install/Classes/Configuration/FeatureInterface.php new file mode 100644 index 0000000000000000000000000000000000000000..aff6dc50cb57d2844e47cfc448dfaf3de71d998d --- /dev/null +++ b/typo3/sysext/install/Classes/Configuration/FeatureInterface.php @@ -0,0 +1,54 @@ +<?php +namespace TYPO3\CMS\Install\Configuration; + +/*************************************************************** + * Copyright notice + * + * (c) 2013 Christian Kuhn <lolli@schwarzbu.ch> + * All rights reserved + * + * This script is part of the TYPO3 project. The TYPO3 project is + * free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * The GNU General Public License can be found at + * http://www.gnu.org/copyleft/gpl.html. + * + * This script is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * This copyright notice MUST APPEAR in all copies of the script! + ***************************************************************/ + +/** + * A feature representation handles preset classes. + */ +interface FeatureInterface { + + /** + * Initialize presets + * + * @param array $postValues List of $POST values of this feature + * @return void + */ + public function initializePresets(array $postValues); + + /** + * Get list of presets ordered by priority + * + * @return array<PresetInterface> + */ + public function getPresetsOrderedByPriority(); + + /** + * Get name of feature + * + * @return string Name + */ + public function getName(); +} +?> \ No newline at end of file diff --git a/typo3/sysext/install/Classes/Configuration/FeatureManager.php b/typo3/sysext/install/Classes/Configuration/FeatureManager.php new file mode 100644 index 0000000000000000000000000000000000000000..442d65593f54fd4d00464c9bdfda99aaa4550fe2 --- /dev/null +++ b/typo3/sysext/install/Classes/Configuration/FeatureManager.php @@ -0,0 +1,136 @@ +<?php +namespace TYPO3\CMS\Install\Configuration; + +/*************************************************************** + * Copyright notice + * + * (c) 2013 Christian Kuhn <lolli@schwarzbu.ch> + * All rights reserved + * + * This script is part of the TYPO3 project. The TYPO3 project is + * free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * The GNU General Public License can be found at + * http://www.gnu.org/copyleft/gpl.html. + * + * This script is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * This copyright notice MUST APPEAR in all copies of the script! + ***************************************************************/ + +/** + * Instantiate and configure all known features and presets + */ +class FeatureManager { + + /** + * @var \TYPO3\CMS\Extbase\Object\ObjectManager + * @inject + */ + protected $objectManager = NULL; + + /** + * @var array List of feature class names + */ + protected $featureRegistry = array( + 'TYPO3\\CMS\\Install\\Configuration\\Charset\\CharsetFeature', + 'TYPO3\\CMS\\Install\\Configuration\\Context\\ContextFeature', + 'TYPO3\\CMS\\Install\\Configuration\\Image\\ImageFeature', + 'TYPO3\\CMS\\Install\\Configuration\\ExtbaseObjectCache\\ExtbaseObjectCacheFeature', + ); + + /** + * Get initialized list of features with possible presets + * + * @param array $postValues List of $POST values + * @return array<FeatureInterface> + * @throws Exception + */ + public function getInitializedFeatures(array $postValues) { + $features = array(); + foreach ($this->featureRegistry as $featureClass) { + /** @var FeatureInterface $featureInstance */ + $featureInstance = $this->objectManager->get($featureClass); + if (!($featureInstance instanceof FeatureInterface)) { + throw new Exception( + 'Feature ' . $featureClass . ' doen not implement FeatureInterface', + 1378644593 + ); + } + $featureInstance->initializePresets($postValues); + $features[] = $featureInstance; + } + return $features; + } + + /** + * Get configuration values to be set to LocalConfiguration from + * list of selected $POST feature presets + * + * @param array $postValues List of $POST values + * @return array List of configuration values + */ + public function getConfigurationForSelectedFeaturePresets(array $postValues) { + $localConfigurationValuesToSet = array(); + $features = $this->getInitializedFeatures($postValues); + foreach ($features as $feature) { + /** @var FeatureInterface $feature */ + $featureName = $feature->getName(); + $presets = $feature->getPresetsOrderedByPriority(); + foreach ($presets as $preset) { + /** @var PresetInterface $preset */ + $presetName = $preset->getName(); + if (!empty($postValues[$featureName]['enable']) + && $postValues[$featureName]['enable'] === $presetName + && (!$preset->isActive() || $preset instanceof CustomPresetInterface) + ) { + $localConfigurationValuesToSet = array_merge( + $localConfigurationValuesToSet, + $preset->getConfigurationValues() + ); + } + } + } + return $localConfigurationValuesToSet; + } + + /** + * Cycle through features and get settings. First matching + * preset (highest priority) will be selected. + * + * @return array Configuration settings + */ + public function getBestMatchingConfigurationForAllFeatures() { + $localConfigurationValuesToSet = array(); + $features = $this->getInitializedFeatures(array()); + foreach ($features as $feature) { + /** @var FeatureInterface $feature */ + $featureName = $feature->getName(); + $presets = $feature->getPresetsOrderedByPriority(); + foreach ($presets as $preset) { + // Only chose "normal" presets, no custom presets + if ($preset instanceof CustomPresetInterface) { + break; + } + + /** @var PresetInterface $preset */ + if ($preset->isAvailable()) { + $localConfigurationValuesToSet = array_merge( + $localConfigurationValuesToSet, + $preset->getConfigurationValues() + ); + // Setting for this feature done, go to next feature + break; + } + } + } + return $localConfigurationValuesToSet; + } +} +?> \ No newline at end of file diff --git a/typo3/sysext/install/Classes/Configuration/Image/AbstractImagePreset.php b/typo3/sysext/install/Classes/Configuration/Image/AbstractImagePreset.php new file mode 100644 index 0000000000000000000000000000000000000000..766ab5beb3cf8d63d4a8dba5cf9ca438963c4fd0 --- /dev/null +++ b/typo3/sysext/install/Classes/Configuration/Image/AbstractImagePreset.php @@ -0,0 +1,165 @@ +<?php +namespace TYPO3\CMS\Install\Configuration\Image; + +/*************************************************************** + * Copyright notice + * + * (c) 2013 Christian Kuhn <lolli@schwarzbu.ch> + * All rights reserved + * + * This script is part of the TYPO3 project. The TYPO3 project is + * free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * The GNU General Public License can be found at + * http://www.gnu.org/copyleft/gpl.html. + * + * This script is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * This copyright notice MUST APPEAR in all copies of the script! + ***************************************************************/ + +use TYPO3\CMS\Install\Configuration; + +/** + * Abstract class implements common image preset code + */ +abstract class AbstractImagePreset extends Configuration\AbstractPreset { + + /** + * @var array Default paths to search for executable, with trailing slash + */ + protected $defaultExecutableSearchPaths = array( + '/usr/local/bin/', + '/opt/local/bin/', + '/usr/bin/', + '/usr/X11R6/bin/', + '/opt/bin/', + 'C:/php/ImageMagick/', + 'C:/php/GraphicsMagick/', + 'C:/apache/ImageMagick/', + 'C:/apache/GraphicsMagick/', + ); + + /** + * @var string Absolute path with found executable + */ + protected $foundPath = ''; + + /** + * Path where executable was found + * + * @return string Fonud path + */ + public function getFoundPath() { + return $this->foundPath; + } + + /** + * Check is preset is currently active on the system. + * Overwrites parent method to ignore im_path and im_path_lzw settings + * + * @return boolean TRUE if preset is active + */ + public function isActive() { + $isActive = TRUE; + foreach ($this->configurationValues as $configurationKey => $configurationValue) { + if ($configurationKey !== 'GFX/im_path' + && $configurationKey !== 'GFX/im_path_lzw' + ) { + $currentValue = $this->configurationManager->getConfigurationValueByPath($configurationKey); + if ($currentValue !== $configurationValue) { + $isActive = FALSE; + break; + } + } + } + return $isActive; + } + + /** + * Find out if GraphicsMagick is available + * + * @return boolean TRUE if GraphicsMagick executable is found in path + */ + public function isAvailable() { + $searchPaths = $this->getSearchPaths(); + return $this->findExecutableInPath($searchPaths); + } + + /** + * Get configuration values to activate prefix + * + * @return array Configuration values needed to activate prefix + */ + public function getConfigurationValues() { + $this->findExecutableInPath($this->getSearchPaths()); + $configurationValues = $this->configurationValues; + $configurationValues['GFX/im_path'] = $this->getFoundPath(); + $configurationValues['GFX/im_path_lzw'] = $this->getFoundPath(); + return $configurationValues; + } + + /** + * Find executable in path, wrapper for specific ImageMagick/GraphicsMagick find methods. + * + * @param array $searchPaths + * @return mixed + */ + abstract protected function findExecutableInPath(array $searchPaths); + + /** + * Get list of paths to search for image handling executables + * + * @return array List of pathes to search for + */ + protected function getSearchPaths() { + $searchPaths = $this->defaultExecutableSearchPaths; + + // Add configured im_path on top + $imPath = $GLOBALS['TYPO3_CONF_VARS']['GFX']['im_path']; + if (strlen($imPath) && !in_array($imPath, $searchPaths)) { + $path = $this->cleanUpPath($imPath); + array_unshift($searchPaths, $path); + } + + // Add configured im_path_lzw on top + $imLzwSearchPath = $GLOBALS['TYPO3_CONF_VARS']['GFX']['im_path_lzw']; + if (strlen($imLzwSearchPath) && !in_array($imLzwSearchPath, $searchPaths)) { + $path = $this->cleanUpPath($imLzwSearchPath); + array_unshift($searchPaths, $path); + } + + // Add additional search path from form if given + if (isset($this->postValues['additionalSearchPath']) + && strlen($this->postValues['additionalSearchPath']) + && !in_array($this->postValues['additionalSearchPath'], $searchPaths) + ) { + $path = $this->cleanUpPath($this->postValues['additionalSearchPath']); + array_unshift($searchPaths, $path); + } + + return $searchPaths; + } + + /** + * Consolidate between Windows and Unix and add trailing slash im missing + * + * @param string $path Given path + * @return string Cleaned up path + */ + protected function cleanUpPath($path) { + $path = \TYPO3\CMS\Core\Utility\GeneralUtility::fixWindowsFilePath($path); + // Add trailing slash if missing + if (!preg_match('/[\\/]$/', $path)) { + $path .= '/'; + } + return $path; + } +} +?> \ No newline at end of file diff --git a/typo3/sysext/install/Classes/Configuration/Image/CustomPreset.php b/typo3/sysext/install/Classes/Configuration/Image/CustomPreset.php new file mode 100644 index 0000000000000000000000000000000000000000..190070f1a247de9ddb16cb15100da184426d0680 --- /dev/null +++ b/typo3/sysext/install/Classes/Configuration/Image/CustomPreset.php @@ -0,0 +1,52 @@ +<?php +namespace TYPO3\CMS\Install\Configuration\Image; + +/*************************************************************** + * Copyright notice + * + * (c) 2013 Christian Kuhn <lolli@schwarzbu.ch> + * All rights reserved + * + * This script is part of the TYPO3 project. The TYPO3 project is + * free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * The GNU General Public License can be found at + * http://www.gnu.org/copyleft/gpl.html. + * + * This script is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * This copyright notice MUST APPEAR in all copies of the script! + ***************************************************************/ + +use TYPO3\CMS\Install\Configuration; + +/** + * Custom preset is a fallback if no other preset fits + */ +class CustomPreset extends Configuration\AbstractCustomPreset implements Configuration\CustomPresetInterface { + + /** + * @var array Configuration values handled by this preset + */ + protected $configurationValues = array( + 'GFX/image_processing' => 0, + 'GFX/im' => 0, + 'GFX/im_path' => '', + 'GFX/im_path_lzw' => '', + 'GFX/im_version_5' => '', + 'GFX/im_negate_mask' => 0, + 'GFX/im_imvMaskState' => 0, + 'GFX/im_no_effects' => 0, + 'GFX/im_v5effects' => 0, + 'GFX/im_mask_temp_ext_gif' => 0, + 'GFX/im_combine_filename' => 'combine', + 'GFX/colorspace' => '', + ); +} +?> \ No newline at end of file diff --git a/typo3/sysext/install/Classes/Configuration/Image/GraphicsMagickPreset.php b/typo3/sysext/install/Classes/Configuration/Image/GraphicsMagickPreset.php new file mode 100644 index 0000000000000000000000000000000000000000..a9239b684f21b9386325025730a2b3b3593b07d1 --- /dev/null +++ b/typo3/sysext/install/Classes/Configuration/Image/GraphicsMagickPreset.php @@ -0,0 +1,102 @@ +<?php +namespace TYPO3\CMS\Install\Configuration\Image; + +/*************************************************************** + * Copyright notice + * + * (c) 2013 Christian Kuhn <lolli@schwarzbu.ch> + * All rights reserved + * + * This script is part of the TYPO3 project. The TYPO3 project is + * free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * The GNU General Public License can be found at + * http://www.gnu.org/copyleft/gpl.html. + * + * This script is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * This copyright notice MUST APPEAR in all copies of the script! + ***************************************************************/ + +use TYPO3\CMS\Install\Configuration; + +/** + * Preset for GraphicsMagick + */ +class GraphicsMagickPreset extends AbstractImagePreset implements Configuration\PresetInterface { + + /** + * @var string Name of preset + */ + protected $name = 'GraphicsMagick'; + + /** + * @var integer Priority of preset + */ + protected $priority = 80; + + /** + * @var array Configuration values handled by this preset + */ + protected $configurationValues = array( + 'GFX/image_processing' => 1, + 'GFX/im' => 1, + // im_path and im_path_lzw are determined and set by path lookup methods + 'GFX/im_path' => '', + 'GFX/im_path_lzw' => '', + 'GFX/im_version_5' => 'gm', + 'GFX/im_negate_mask' => 0, + 'GFX/im_imvMaskState' => 0, + 'GFX/im_no_effects' => 1, + 'GFX/im_v5effects' => -1, + 'GFX/im_mask_temp_ext_gif' => 1, + 'GFX/colorspace' => 'RGB', + ); + + /** + * Find executable in path, wrapper for specific ImageMagick/GraphicsMagick find methods. + * + * @param array $searchPaths + * @return mixed + */ + protected function findExecutableInPath(array $searchPaths) { + return $this->findGraphicsMagickInPaths($searchPaths); + } + + /** + * Search for GraphicsMagick executables in given paths. + * + * @param array $searchPaths List of pathes to search for + * @return boolean TRUE if graphics magick was found in path + */ + protected function findGraphicsMagickInPaths(array $searchPaths) { + $result = FALSE; + foreach ($searchPaths as $path) { + if (TYPO3_OS === 'WIN') { + $executable = 'gm.exe'; + } else { + $executable = 'gm'; + } + if (@is_dir($path) && @is_file($path . $executable)) { + $command = escapeshellarg($path . $executable) . ' -version'; + $executingResult = FALSE; + \TYPO3\CMS\Core\Utility\CommandUtility::exec($command, $executingResult); + // First line of exec command should contain string GraphicsMagick + $firstResultLine = array_shift($executingResult); + if (strpos($firstResultLine, 'GraphicsMagick') !== FALSE) { + $this->foundPath = $path; + $result = TRUE; + break; + } + } + } + return $result; + } +} +?> \ No newline at end of file diff --git a/typo3/sysext/install/Classes/Configuration/Image/ImageFeature.php b/typo3/sysext/install/Classes/Configuration/Image/ImageFeature.php new file mode 100644 index 0000000000000000000000000000000000000000..0890b612f02f7a53adc1bdea97d3a872c0eaad1d --- /dev/null +++ b/typo3/sysext/install/Classes/Configuration/Image/ImageFeature.php @@ -0,0 +1,62 @@ +<?php +namespace TYPO3\CMS\Install\Configuration\Image; + +/*************************************************************** + * Copyright notice + * + * (c) 2013 Christian Kuhn <lolli@schwarzbu.ch> + * All rights reserved + * + * This script is part of the TYPO3 project. The TYPO3 project is + * free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * The GNU General Public License can be found at + * http://www.gnu.org/copyleft/gpl.html. + * + * This script is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * This copyright notice MUST APPEAR in all copies of the script! + ***************************************************************/ + +use TYPO3\CMS\Install\Configuration; + +/** + * Image feature detects imagemagick / graphicsmagick versions + */ +class ImageFeature extends Configuration\AbstractFeature implements Configuration\FeatureInterface { + + /** + * @var string Name of feature + */ + protected $name = 'Image'; + + /** + * @var array List of preset classes + */ + protected $presetRegistry = array( + 'TYPO3\\CMS\\Install\\Configuration\\Image\\GraphicsMagickPreset', + 'TYPO3\\CMS\\Install\\Configuration\\Image\\ImageMagick6Preset', + 'TYPO3\\CMS\\Install\\Configuration\\Image\\CustomPreset', + ); + + /** + * Image feature can be feeded with an additional path to search for executables, + * this getter returns the given input string (for Fluid) + * + * @return string + */ + public function getAdditionalSearchPath() { + $additionalPath = ''; + if (isset($this->postValues['additionalSearchPath']) && strlen($this->postValues['additionalSearchPath'])) { + $additionalPath = $this->postValues['additionalSearchPath']; + } + return $additionalPath; + } +} +?> \ No newline at end of file diff --git a/typo3/sysext/install/Classes/Configuration/Image/ImageMagick6Preset.php b/typo3/sysext/install/Classes/Configuration/Image/ImageMagick6Preset.php new file mode 100644 index 0000000000000000000000000000000000000000..d292f931b6931ecfef5e782fc8d8fb2a7fd39f90 --- /dev/null +++ b/typo3/sysext/install/Classes/Configuration/Image/ImageMagick6Preset.php @@ -0,0 +1,109 @@ +<?php +namespace TYPO3\CMS\Install\Configuration\Image; + +/*************************************************************** + * Copyright notice + * + * (c) 2013 Christian Kuhn <lolli@schwarzbu.ch> + * All rights reserved + * + * This script is part of the TYPO3 project. The TYPO3 project is + * free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * The GNU General Public License can be found at + * http://www.gnu.org/copyleft/gpl.html. + * + * This script is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * This copyright notice MUST APPEAR in all copies of the script! + ***************************************************************/ + +use TYPO3\CMS\Install\Configuration; + +/** + * Preset for ImageMagick version 6 or higher + */ +class ImageMagick6Preset extends AbstractImagePreset implements Configuration\PresetInterface { + + /** + * @var string Name of preset + */ + protected $name = 'ImageMagick6'; + + /** + * @var integer Priority of preset + */ + protected $priority = 70; + + /** + * @var array Configuration values handled by this preset + */ + protected $configurationValues = array( + 'GFX/image_processing' => 1, + 'GFX/im' => 1, + // im_path and im_path_lzw are determined and set by path lookup methods + 'GFX/im_path' => '', + 'GFX/im_path_lzw' => '', + 'GFX/im_version_5' => 'im6', + 'GFX/im_negate_mask' => 0, + 'GFX/im_imvMaskState' => 1, + 'GFX/im_no_effects' => 1, + 'GFX/im_v5effects' => 1, + 'GFX/im_mask_temp_ext_gif' => 1, + 'GFX/im_combine_filename' => 'composite', + 'GFX/colorspace' => 'RGB', + ); + + /** + * Find executable in path, wrapper for specific ImageMagick/GraphicsMagick find methods. + * + * @param array $searchPaths + * @return mixed + */ + protected function findExecutableInPath(array $searchPaths) { + return $this->findImageMagick6InPaths($searchPaths); + } + + /** + * Search for GraphicsMagick executables in given paths. + * + * @param array $searchPaths List of paths to search for + * @return boolean TRUE if graphics magick was found in path + */ + protected function findImageMagick6InPaths(array $searchPaths) { + $result = FALSE; + foreach ($searchPaths as $path) { + if (TYPO3_OS === 'WIN') { + $executable = 'identify.exe'; + } else { + $executable = 'identify'; + } + if (@is_dir($path) && @is_file($path . $executable)) { + $command = escapeshellarg($path . $executable) . ' -version'; + $executingResult = FALSE; + \TYPO3\CMS\Core\Utility\CommandUtility::exec($command, $executingResult); + // First line of exec command should contain string GraphicsMagick + $firstResultLine = array_shift($executingResult); + // Example: "Version: ImageMagick 6.6.0-4 2012-05-02 Q16 http://www.imagemagick.org" + if (strpos($firstResultLine, 'ImageMagick') !== FALSE) { + list(,$version) = explode('ImageMagick', $firstResultLine); + // Example: "6.6.0-4" + list($version) = explode(' ',trim($version)); + if (version_compare($version, '6.0.0') >= 0) { + $this->foundPath = $path; + $result = TRUE; + break; + } + } + } + } + return $result; + } +} +?> \ No newline at end of file diff --git a/typo3/sysext/install/Classes/Configuration/PresetInterface.php b/typo3/sysext/install/Classes/Configuration/PresetInterface.php new file mode 100644 index 0000000000000000000000000000000000000000..3582841681b6b9b5d5c3e2900d75b7329bc74156 --- /dev/null +++ b/typo3/sysext/install/Classes/Configuration/PresetInterface.php @@ -0,0 +1,94 @@ +<?php +namespace TYPO3\CMS\Install\Configuration; + +/*************************************************************** + * Copyright notice + * + * (c) 2013 Christian Kuhn <lolli@schwarzbu.ch> + * All rights reserved + * + * This script is part of the TYPO3 project. The TYPO3 project is + * free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * The GNU General Public License can be found at + * http://www.gnu.org/copyleft/gpl.html. + * + * This script is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * This copyright notice MUST APPEAR in all copies of the script! + ***************************************************************/ + +use TYPO3\CMS\Core\Utility\GeneralUtility; + +/** + * Preset interface + * + * A preset is a class for handling a specific configuration + * set of a feature. + */ +interface PresetInterface { + + /** + * Set POST values + * + * @param array $postValues Post values of feature + * @return mixed + */ + public function setPostValues(array $postValues); + + /** + * Check if preset is available on the system + * + * @return boolean TRUE if preset is available + */ + public function isAvailable(); + + /** + * Wrapper for isAvailable, used in fluid + * + * @return boolean TRUE if preset is available + */ + public function getIsAvailable(); + + /** + * Check is preset is currently active on the system + * + * @return boolean TRUE if preset is active + */ + public function isActive(); + + /** + * Wrapper for isActive, used in fluid + * + * @return boolean TRUE if preset is active + */ + public function getIsActive(); + + /** + * Get name of preset + * + * @return string Name + */ + public function getName(); + + /** + * Get priority of preset + * + * @return integer Priority, usually between 0 and 100 + */ + public function getPriority(); + + /** + * Get configuration values to activate prefix + * + * @return array Configuration values needed to activate prefix + */ + public function getConfigurationValues(); +} +?> \ No newline at end of file diff --git a/typo3/sysext/install/Classes/Controller/Action/Step/DefaultConfiguration.php b/typo3/sysext/install/Classes/Controller/Action/Step/DefaultConfiguration.php index 487f2fb44a1a5f8acfa9e88917606e4282363d07..f3024b2b525e82118ef22fe0c7772e9bf6d1b23a 100644 --- a/typo3/sysext/install/Classes/Controller/Action/Step/DefaultConfiguration.php +++ b/typo3/sysext/install/Classes/Controller/Action/Step/DefaultConfiguration.php @@ -37,11 +37,17 @@ class DefaultConfiguration extends Action\AbstractAction implements StepInterfac * @return array<\TYPO3\CMS\Install\Status\StatusInterface> */ public function execute() { - // @TODO: Implement "auto configuration" + /** @var \TYPO3\CMS\Install\Configuration\FeatureManager $featureManager */ + $featureManager = $this->objectManager->get('TYPO3\\CMS\\Install\\Configuration\\FeatureManager'); + // Get best matching configuration presets + $configurationValues = $featureManager->getBestMatchingConfigurationForAllFeatures(); + + // Setting SYS/isInitialInstallationInProgress to FALSE marks this instance installation as complete + $configurationValues['SYS/isInitialInstallationInProgress'] = FALSE; /** @var $configurationManager \TYPO3\CMS\Core\Configuration\ConfigurationManager */ $configurationManager = $this->objectManager->get('TYPO3\\CMS\\Core\\Configuration\\ConfigurationManager'); - $configurationManager->setLocalConfigurationValueByPath('SYS/isInitialInstallationInProgress', FALSE); + $configurationManager->setLocalConfigurationValuesByPathValuePairs($configurationValues); /** @var \TYPO3\CMS\Install\Service\SessionService $session */ $session = $this->objectManager->get('TYPO3\\CMS\\Install\\Service\\SessionService'); diff --git a/typo3/sysext/install/Classes/Controller/Action/Tool/Configuration.php b/typo3/sysext/install/Classes/Controller/Action/Tool/Configuration.php new file mode 100644 index 0000000000000000000000000000000000000000..703524a3a7914d78fd6968f82a41d306a4f9f832 --- /dev/null +++ b/typo3/sysext/install/Classes/Controller/Action/Tool/Configuration.php @@ -0,0 +1,93 @@ +<?php +namespace TYPO3\CMS\Install\Controller\Action\Tool; + +/*************************************************************** + * Copyright notice + * + * (c) 2013 Christian Kuhn <lolli@schwarzbu.ch> + * All rights reserved + * + * This script is part of the TYPO3 project. The TYPO3 project is + * free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * The GNU General Public License can be found at + * http://www.gnu.org/copyleft/gpl.html. + * + * This script is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * This copyright notice MUST APPEAR in all copies of the script! + ***************************************************************/ + +use TYPO3\CMS\Install\Controller\Action; + +/** + * Show configuration features and handle presets + */ +class Configuration extends Action\AbstractAction implements Action\ActionInterface { + + /** + * @var \TYPO3\CMS\Install\Configuration\FeatureManager + * @inject + */ + protected $featureManager; + + /** + * @var \TYPO3\CMS\Core\Configuration\ConfigurationManager + * @inject + */ + protected $configurationManager = NULL; + + /** + * Handle this action + * + * @return string content + */ + public function handle() { + $this->initializeHandle(); + + $actionMessages = array(); + if (isset($this->postValues['set']['activate'])) { + $actionMessages[] = $this->activate(); + $this->activate(); + } + $this->view->assign('actionMessages', $actionMessages); + + $postValues = is_array($this->postValues['values']) ? $this->postValues['values'] : array(); + $this->view->assign('features', $this->featureManager->getInitializedFeatures($postValues)); + + return $this->view->render(); + } + + /** + * Configure selected feature presets to be active + * + * @return \TYPO3\CMS\Install\Status\StatusInterface + */ + protected function activate() { + $configurationValues = $this->featureManager->getConfigurationForSelectedFeaturePresets($this->postValues['values']); + + if (count($configurationValues) > 0) { + $this->configurationManager->setLocalConfigurationValuesByPathValuePairs($configurationValues); + /** @var $message \TYPO3\CMS\Install\Status\StatusInterface */ + $message = $this->objectManager->get('TYPO3\\CMS\\Install\\Status\\OkStatus'); + $message->setTitle('Configuration written'); + $messageBody = array(); + foreach ($configurationValues as $configurationKey => $configurationValue) { + $messageBody[] = '\'' . $configurationKey . '\' => \'' . $configurationValue . '\''; + } + $message->setMessage(implode(LF, $messageBody)); + } else { + /** @var $message \TYPO3\CMS\Install\Status\StatusInterface */ + $message = $this->objectManager->get('TYPO3\\CMS\\Install\\Status\\InfoStatus'); + $message->setTitle('No configuration change selected'); + } + return $message; + } +} +?> diff --git a/typo3/sysext/install/Classes/Controller/ToolController.php b/typo3/sysext/install/Classes/Controller/ToolController.php index 890ff140e5b88a21e1ffbd966854256562b38eea..504a8fb0a5ebe8d59555d0a511e8987f76f620e8 100644 --- a/typo3/sysext/install/Classes/Controller/ToolController.php +++ b/typo3/sysext/install/Classes/Controller/ToolController.php @@ -42,6 +42,7 @@ class ToolController extends AbstractController { 'welcome', 'importantActions', 'systemEnvironment', + 'configuration', 'folderStructure', 'testSetup', 'updateWizard', diff --git a/typo3/sysext/install/Resources/Private/Partials/Action/Common/Left.html b/typo3/sysext/install/Resources/Private/Partials/Action/Common/Left.html index e55e545be2edc7c66a18b91e62a5107c377c4b91..283bbd5d353aa2ed9ea6723790fafdcface341d4 100644 --- a/typo3/sysext/install/Resources/Private/Partials/Action/Common/Left.html +++ b/typo3/sysext/install/Resources/Private/Partials/Action/Common/Left.html @@ -18,6 +18,11 @@ </f:if> </a> </li> + <li id="t3-install-menu-configuration" class="{f:if(condition:'{action} == \'configuration\'', then:'act')}"> + <a href="Install.php?install[action]=configuration&install[context]={context}&install[controller]=tool"> + Configuration Presets + </a> + </li> <li id="t3-install-menu-folderStructure" class="{f:if(condition:'{action} == \'folderStructure\'', then:'act')}"> <a href="Install.php?install[action]=folderStructure&install[context]={context}&install[controller]=tool"> Folder structure diff --git a/typo3/sysext/install/Resources/Private/Partials/Action/Tool/Configuration/Charset.html b/typo3/sysext/install/Resources/Private/Partials/Action/Tool/Configuration/Charset.html new file mode 100644 index 0000000000000000000000000000000000000000..c80f237322ac31ea57c1b6847feaf6123bdd59ba --- /dev/null +++ b/typo3/sysext/install/Resources/Private/Partials/Action/Tool/Configuration/Charset.html @@ -0,0 +1,20 @@ +<div class="toggleGroup"> + <div class="toggleButton"> + <h4>Character set conversion settings</h4> + </div> + + <div class="toggleData" style="display:none"> + <p> + Charset conversion is done at various places in the TYPO3 CMS core + and can lead to massive performance problems if not set right. In + general the first available setting should be selected for maximum + performance and least problems. + </p> + + <f:for each="{feature.presetsOrderedByPriority}" as="preset"> + <f:render partial="Action/Tool/Configuration/{feature.name}/{preset.name}" arguments="{_all}" /> + </f:for> + </div> +</div> + +<hr /> \ No newline at end of file diff --git a/typo3/sysext/install/Resources/Private/Partials/Action/Tool/Configuration/Charset/CoreInternal.html b/typo3/sysext/install/Resources/Private/Partials/Action/Tool/Configuration/Charset/CoreInternal.html new file mode 100644 index 0000000000000000000000000000000000000000..df14bbe0bbfa656b78fca249b07d1ff67056d81a --- /dev/null +++ b/typo3/sysext/install/Resources/Private/Partials/Action/Tool/Configuration/Charset/CoreInternal.html @@ -0,0 +1,29 @@ +<div class="typo3-message message-warning"> + <div class="header-container"> + <div class="message-header"> + <input + type="radio" + class="t3-install-tool-configuration-radio" + id="t3-install-tool-configuration-charset-coreinternal" + name="install[values][{feature.name}][enable]" + value="{preset.name}" + {f:if(condition:'{preset.isActive}', then:'checked="checked"')} + /> + <label + for="t3-install-tool-configuration-charset-coreinternal" + class="t3-install-tool-configuration-radio-label" + > + <strong> + Internal core handling + </strong> + {f:if(condition:'{preset.isActive}', then:' [Active]')} + </label> + </div> + </div> + <div class="message-body>"> + Internal core charset handling is a fallback if neither mbstring nor iconv + is available. It is very slow, deprecated and buggy. Use this only if there + is no other option available and upgrade your system to include mbstring soon. + </div> +</div> +<p></p> \ No newline at end of file diff --git a/typo3/sysext/install/Resources/Private/Partials/Action/Tool/Configuration/Charset/Custom.html b/typo3/sysext/install/Resources/Private/Partials/Action/Tool/Configuration/Charset/Custom.html new file mode 100644 index 0000000000000000000000000000000000000000..12333118a2801f0419e4cf22f1f618714fa715ec --- /dev/null +++ b/typo3/sysext/install/Resources/Private/Partials/Action/Tool/Configuration/Charset/Custom.html @@ -0,0 +1,43 @@ +<div class="typo3-message message-warning"> + <div class="header-container"> + <div class="message-header"> + <input + type="radio" + class="t3-install-tool-configuration-radio" + id="t3-install-tool-configuration-charset-custom" + name="install[values][{feature.name}][enable]" + value="{preset.name}" + {f:if(condition:'{preset.isActive}', then:'checked="checked"')} + /> + <label + for="t3-install-tool-configuration-charset-custom" + class="t3-install-tool-configuration-radio-label" + > + <strong> + Custom configuration + </strong> + {f:if(condition:'{preset.isActive}', then:' [Active]')} + </label> + </div> + </div> + <div class="message-body>"> + <p> + Custom configuration can be set here. The charset configuration supports + only a limited set of configuration variants. If this preset is activated + it is a sign for a not valid configuration and should be switched to one + of the configurations above. + </p> + + <f:for each="{preset.configurationValues}" as="configurationValue" key="configurationKey"> + <div> + <input + type="input" + name="install[values][{feature.name}][{preset.name}][{configurationKey}]" + value="{configurationValue}" + /> + {configurationKey} + </div> + </f:for> + </div> +</div> +<p></p> \ No newline at end of file diff --git a/typo3/sysext/install/Resources/Private/Partials/Action/Tool/Configuration/Charset/Iconv.html b/typo3/sysext/install/Resources/Private/Partials/Action/Tool/Configuration/Charset/Iconv.html new file mode 100644 index 0000000000000000000000000000000000000000..77da924373f5e498955860030f592fd06e12fa5b --- /dev/null +++ b/typo3/sysext/install/Resources/Private/Partials/Action/Tool/Configuration/Charset/Iconv.html @@ -0,0 +1,29 @@ +<div class="typo3-message {f:if(condition:'{preset.isAvailable}', then:'message-ok', else:'message-error')}"> + <div class="header-container"> + <div class="message-header"> + <input + type="radio" + class="t3-install-tool-configuration-radio" + id="t3-install-tool-configuration-charset-iconv" + name="install[values][{feature.name}][enable]" + value="{preset.name}" + {f:if(condition:'{preset.isAvailable}', then:'', else:'disabled="disabled"')} + {f:if(condition:'{preset.isActive}', then:'checked="checked"')} + /> + <label + for="t3-install-tool-configuration-charset-iconv" + class="t3-install-tool-configuration-radio-label" + > + <strong> + iconv + </strong> + {f:if(condition:'{preset.isActive}', then:' [Active]')} + </label> + </div> + </div> + <div class="message-body>"> + iconv implementation is based on a PHP module. It works well but + mbstring should be preferred if available. + </div> +</div> +<p></p> \ No newline at end of file diff --git a/typo3/sysext/install/Resources/Private/Partials/Action/Tool/Configuration/Charset/Mbstring.html b/typo3/sysext/install/Resources/Private/Partials/Action/Tool/Configuration/Charset/Mbstring.html new file mode 100644 index 0000000000000000000000000000000000000000..de31bafdad71d33674bcab579f4e2d41cab49e28 --- /dev/null +++ b/typo3/sysext/install/Resources/Private/Partials/Action/Tool/Configuration/Charset/Mbstring.html @@ -0,0 +1,28 @@ +<div class="typo3-message {f:if(condition:'{preset.isAvailable}', then:'message-ok', else:'message-error')}"> + <div class="header-container"> + <div class="message-header"> + <input + type="radio" + class="t3-install-tool-configuration-radio" + id="t3-install-tool-configuration-charset-mbstring" + name="install[values][{feature.name}][enable]" + value="{preset.name}" + {f:if(condition:'{preset.isAvailable}', then:'', else:'disabled="disabled"')} + {f:if(condition:'{preset.isActive}', then:'checked="checked"')} + /> + <label + for="t3-install-tool-configuration-charset-mbstring" + class="t3-install-tool-configuration-radio-label" + > + <strong> + mbstring + </strong> + {f:if(condition:'{preset.isActive}', then:' [Active]')} + </label> + </div> + </div> + <div class="message-body>"> + mbstring conversion is based on a PHP module and usually the quickest implementation. + </div> +</div> +<p></p> \ No newline at end of file diff --git a/typo3/sysext/install/Resources/Private/Partials/Action/Tool/Configuration/Context.html b/typo3/sysext/install/Resources/Private/Partials/Action/Tool/Configuration/Context.html new file mode 100644 index 0000000000000000000000000000000000000000..244087368be221998cf008b48040763a5e68f7c2 --- /dev/null +++ b/typo3/sysext/install/Resources/Private/Partials/Action/Tool/Configuration/Context.html @@ -0,0 +1,26 @@ +<div class="toggleGroup"> + <div class="toggleButton"> + <h4>Development / Production settings</h4> + </div> + + <div class="toggleData" style="display:none"> + <p> + A set of configuration options should be different if the current + environment is a development or a production system. The goal is + to configure a production instance with maximum performance and no + debug output that is possibly shown to users, while development + instances should enable error output. + </p> + <p> + The environment can be defined with the environment variable + "TYPO3_CONTEXT" set to "Production" or "Development". If no context + environment variable is set, "Production" is assumed. + </p> + + <f:for each="{feature.presetsOrderedByPriority}" as="preset"> + <f:render partial="Action/Tool/Configuration/{feature.name}/{preset.name}" arguments="{_all}" /> + </f:for> + </div> +</div> + +<hr /> \ No newline at end of file diff --git a/typo3/sysext/install/Resources/Private/Partials/Action/Tool/Configuration/Context/Custom.html b/typo3/sysext/install/Resources/Private/Partials/Action/Tool/Configuration/Context/Custom.html new file mode 100644 index 0000000000000000000000000000000000000000..1b1fe0810d7e4a0238b22b4c119d264f32e9cbb3 --- /dev/null +++ b/typo3/sysext/install/Resources/Private/Partials/Action/Tool/Configuration/Context/Custom.html @@ -0,0 +1,40 @@ +<div class="typo3-message message-warning"> + <div class="header-container"> + <div class="message-header"> + <input + type="radio" + class="t3-install-tool-configuration-radio" + id="t3-install-tool-configuration-context-custom" + name="install[values][{feature.name}][enable]" + value="{preset.name}" + {f:if(condition:'{preset.isActive}', then:'checked="checked"')} + /> + <label + for="t3-install-tool-configuration-context-custom" + class="t3-install-tool-configuration-radio-label" + > + <strong> + Custom configuration + </strong> + {f:if(condition:'{preset.isActive}', then:' [Active]')} + </label> + </div> + </div> + <div class="message-body>"> + <p> + Custom configuration mixture if no other preset fits. + </p> + + <f:for each="{preset.configurationValues}" as="configurationValue" key="configurationKey"> + <div> + <input + type="input" + name="install[values][{feature.name}][{preset.name}][{configurationKey}]" + value="{configurationValue}" + /> + {configurationKey} + </div> + </f:for> + </div> +</div> +<p></p> \ No newline at end of file diff --git a/typo3/sysext/install/Resources/Private/Partials/Action/Tool/Configuration/Context/Development.html b/typo3/sysext/install/Resources/Private/Partials/Action/Tool/Configuration/Context/Development.html new file mode 100644 index 0000000000000000000000000000000000000000..2a379d5fea2f619f418321b7cd64b25b325acde6 --- /dev/null +++ b/typo3/sysext/install/Resources/Private/Partials/Action/Tool/Configuration/Context/Development.html @@ -0,0 +1,28 @@ +<div class="typo3-message message-ok"> + <div class="header-container"> + <div class="message-header"> + <input + type="radio" + class="t3-install-tool-configuration-radio" + id="t3-install-tool-configuration-context-development" + name="install[values][{feature.name}][enable]" + value="{preset.name}" + {f:if(condition:'{preset.isActive}', then:'checked="checked"')} + /> + <label + for="t3-install-tool-configuration-context-development" + class="t3-install-tool-configuration-radio-label" + > + <strong> + Development + </strong> + {f:if(condition:'{preset.isActive}', then:' [Active]')} + </label> + </div> + </div> + <div class="message-body>"> + Development settings enable debug output, deprecation logs + and set logging to info level. + </div> +</div> +<p></p> \ No newline at end of file diff --git a/typo3/sysext/install/Resources/Private/Partials/Action/Tool/Configuration/Context/Production.html b/typo3/sysext/install/Resources/Private/Partials/Action/Tool/Configuration/Context/Production.html new file mode 100644 index 0000000000000000000000000000000000000000..90dc4584aa484d0727ab831707c993ceaefbbbe4 --- /dev/null +++ b/typo3/sysext/install/Resources/Private/Partials/Action/Tool/Configuration/Context/Production.html @@ -0,0 +1,28 @@ +<div class="typo3-message message-ok"> + <div class="header-container"> + <div class="message-header"> + <input + type="radio" + class="t3-install-tool-configuration-radio" + id="t3-install-tool-configuration-context-production" + name="install[values][{feature.name}][enable]" + value="{preset.name}" + {f:if(condition:'{preset.isActive}', then:'checked="checked"')} + /> + <label + for="t3-install-tool-configuration-context-production" + class="t3-install-tool-configuration-radio-label" + > + <strong> + Production + </strong> + {f:if(condition:'{preset.isActive}', then:' [Active]')} + </label> + </div> + </div> + <div class="message-body>"> + Production settings turn off debug output, deprecation logs + and set logging to warnings and errors only. + </div> +</div> +<p></p> \ No newline at end of file diff --git a/typo3/sysext/install/Resources/Private/Partials/Action/Tool/Configuration/ExtbaseObjectCache.html b/typo3/sysext/install/Resources/Private/Partials/Action/Tool/Configuration/ExtbaseObjectCache.html new file mode 100644 index 0000000000000000000000000000000000000000..62620755648dae2b40dffa0d478f8c0afe4883cb --- /dev/null +++ b/typo3/sysext/install/Resources/Private/Partials/Action/Tool/Configuration/ExtbaseObjectCache.html @@ -0,0 +1,24 @@ +<div class="toggleGroup"> + <div class="toggleButton"> + <h4>Extbase object cache</h4> + </div> + + <div class="toggleData" style="display:none"> + <p> + To speed up object instantiation Extbase stores some cache data. This can lead + to lots of SELECT database queries on each page hit if the cache is configured + to use the default database cache backend. + </p> + <p> + This cache can not grow very big, it uses no tagging and is used multiple times + for one request. These characteristics make it well suited to be used in + combination with a APC cache backend. + </p> + + <f:for each="{feature.presetsOrderedByPriority}" as="preset"> + <f:render partial="Action/Tool/Configuration/{feature.name}/{preset.name}" arguments="{_all}" /> + </f:for> + </div> +</div> + +<hr /> \ No newline at end of file diff --git a/typo3/sysext/install/Resources/Private/Partials/Action/Tool/Configuration/ExtbaseObjectCache/Apc.html b/typo3/sysext/install/Resources/Private/Partials/Action/Tool/Configuration/ExtbaseObjectCache/Apc.html new file mode 100644 index 0000000000000000000000000000000000000000..aa3f0d8e7519b7368caed221604caf2c5b90c22b --- /dev/null +++ b/typo3/sysext/install/Resources/Private/Partials/Action/Tool/Configuration/ExtbaseObjectCache/Apc.html @@ -0,0 +1,38 @@ +<div class="typo3-message {f:if(condition:'{preset.isAvailable}', then:'message-ok', else:'message-warning')}"> + <div class="header-container"> + <div class="message-header"> + <input + type="radio" + class="t3-install-tool-configuration-radio" + id="t3-install-tool-configuration-extbaseobjectcache-apc" + name="install[values][{feature.name}][enable]" + value="{preset.name}" + {f:if(condition:'{preset.isAvailable}', then:'', else:'disabled="disabled"')} + {f:if(condition:'{preset.isActive}', then:'checked="checked"')} + /> + <label + for="t3-install-tool-configuration-extbaseobjectcache-apc" + class="t3-install-tool-configuration-radio-label" + > + <strong> + APC cache backend + </strong> + {f:if(condition:'{preset.isActive}', then:' [Active]')} + </label> + </div> + </div> + <div class="message-body>"> + <f:if condition="{preset.isAvailable}"> + <f:then> + Use APC cache backend. This reduces your MySQL load and + speeds up lots of TYPO3 CMS requests. Use if available. + </f:then> + <f:else> + APC is not loaded or not enough memory is left. APC should + be configured to have at least 100MB of shared memory with + 5MB free memory. + </f:else> + </f:if> + </div> +</div> +<p></p> \ No newline at end of file diff --git a/typo3/sysext/install/Resources/Private/Partials/Action/Tool/Configuration/ExtbaseObjectCache/Database.html b/typo3/sysext/install/Resources/Private/Partials/Action/Tool/Configuration/ExtbaseObjectCache/Database.html new file mode 100644 index 0000000000000000000000000000000000000000..79e7a485c2bfe06a952acc147a5c8f4fa92f25e6 --- /dev/null +++ b/typo3/sysext/install/Resources/Private/Partials/Action/Tool/Configuration/ExtbaseObjectCache/Database.html @@ -0,0 +1,28 @@ +<div class="typo3-message message-ok"> + <div class="header-container"> + <div class="message-header"> + <input + type="radio" + class="t3-install-tool-configuration-radio" + id="t3-install-tool-configuration-extbaseobjectcache-database" + name="install[values][{feature.name}][enable]" + value="{preset.name}" + {f:if(condition:'{preset.isActive}', then:'checked="checked"')} + /> + <label + for="t3-install-tool-configuration-extbaseobjectcache-database" + class="t3-install-tool-configuration-radio-label" + > + <strong> + Database cache backend + </strong> + {f:if(condition:'{preset.isActive}', then:' [Active]')} + </label> + </div> + </div> + <div class="message-body>"> + This default cache backend is always available and a + fallback if APC is not available. + </div> +</div> +<p></p> \ No newline at end of file diff --git a/typo3/sysext/install/Resources/Private/Partials/Action/Tool/Configuration/Image.html b/typo3/sysext/install/Resources/Private/Partials/Action/Tool/Configuration/Image.html new file mode 100644 index 0000000000000000000000000000000000000000..67eee57bcd0b5f38d058219d08cfc9666d60d136 --- /dev/null +++ b/typo3/sysext/install/Resources/Private/Partials/Action/Tool/Configuration/Image.html @@ -0,0 +1,37 @@ +<div class="toggleGroup"> + <div class="toggleButton"> + <h4>Image handling settings</h4> + </div> + + <div class="toggleData" style="display:none"> + <p> + Advanced image handling in TYPO3 CMS uses the command line tools + GraphicsMagick or ImageMagick. The tools need to be configured + correctly depending on the version that is available on the system. + </p> + <p> + This module detects the available image handling versions and sets + the system accordingly. If everything is correctly set up the image + tests of the install tool section "Test setup" should be fine. + </p> + + <p> + If ImageMagick or GraphicsMagick executables are located at some + not standard place, add the absolute directory name here. + </p> + <p> + <input + type="input" + name="install[values][{feature.name}][additionalSearchPath]" + value="{feature.additionalSearchPath}" + /> + <button type="submit" name="install[set][ImageSearch]">Find executables in this directory</button> + </p> + + <f:for each="{feature.presetsOrderedByPriority}" as="preset"> + <f:render partial="Action/Tool/Configuration/{feature.name}/{preset.name}" arguments="{_all}" /> + </f:for> + </div> +</div> + +<hr /> \ No newline at end of file diff --git a/typo3/sysext/install/Resources/Private/Partials/Action/Tool/Configuration/Image/Custom.html b/typo3/sysext/install/Resources/Private/Partials/Action/Tool/Configuration/Image/Custom.html new file mode 100644 index 0000000000000000000000000000000000000000..f716a16492d381b54beaa82175c7d34997bdfd8a --- /dev/null +++ b/typo3/sysext/install/Resources/Private/Partials/Action/Tool/Configuration/Image/Custom.html @@ -0,0 +1,40 @@ +<div class="typo3-message message-warning"> + <div class="header-container"> + <div class="message-header"> + <input + type="radio" + class="t3-install-tool-configuration-radio" + id="t3-install-tool-configuration-image-custom" + name="install[values][{feature.name}][enable]" + value="{preset.name}" + {f:if(condition:'{preset.isActive}', then:'checked="checked"')} + /> + <label + for="t3-install-tool-configuration-image-custom" + class="t3-install-tool-configuration-radio-label" + > + <strong> + Custom configuration + </strong> + {f:if(condition:'{preset.isActive}', then:' [Active]')} + </label> + </div> + </div> + <div class="message-body>"> + <p> + Custom configuration mixture if no other preset fits. + </p> + + <f:for each="{preset.configurationValues}" as="configurationValue" key="configurationKey"> + <div> + <input + type="input" + name="install[values][{feature.name}][{preset.name}][{configurationKey}]" + value="{configurationValue}" + /> + {configurationKey} + </div> + </f:for> + </div> +</div> +<p></p> \ No newline at end of file diff --git a/typo3/sysext/install/Resources/Private/Partials/Action/Tool/Configuration/Image/GraphicsMagick.html b/typo3/sysext/install/Resources/Private/Partials/Action/Tool/Configuration/Image/GraphicsMagick.html new file mode 100644 index 0000000000000000000000000000000000000000..61c24ea0a33c6e976889c53144d4d5d7704d7f2e --- /dev/null +++ b/typo3/sysext/install/Resources/Private/Partials/Action/Tool/Configuration/Image/GraphicsMagick.html @@ -0,0 +1,37 @@ +<div class="typo3-message {f:if(condition:'{preset.isAvailable}', then:'message-ok', else:'message-error')}"> + <div class="header-container"> + <div class="message-header"> + <input + type="radio" + class="t3-install-tool-configuration-radio" + id="t3-install-tool-configuration-image-graphicsmagick" + name="install[values][{feature.name}][enable]" + value="{preset.name}" + {f:if(condition:'{preset.isAvailable}', then:'', else:'disabled="disabled"')} + {f:if(condition:'{preset.isActive}', then:'checked="checked"')} + /> + <label + for="t3-install-tool-configuration-image-graphicsmagick" + class="t3-install-tool-configuration-radio-label" + > + <strong> + Graphics Magick + </strong> + {f:if(condition:'{preset.isActive}', then:' [Active]')} + </label> + </div> + </div> + <div class="message-body>"> + <f:if condition="{preset.isAvailable}"> + <f:then> + GraphicsMagick was found in path {preset.foundPath} + </f:then> + <f:else> + GraphicsMagick was not found in standard system paths. If it is + installed at an unusual location at your system, add the path to the + input box above and search again. + </f:else> + </f:if> + </div> +</div> +<p></p> \ No newline at end of file diff --git a/typo3/sysext/install/Resources/Private/Partials/Action/Tool/Configuration/Image/ImageMagick6.html b/typo3/sysext/install/Resources/Private/Partials/Action/Tool/Configuration/Image/ImageMagick6.html new file mode 100644 index 0000000000000000000000000000000000000000..000f7625b470000c2f368e6918cbc6df2b793e6f --- /dev/null +++ b/typo3/sysext/install/Resources/Private/Partials/Action/Tool/Configuration/Image/ImageMagick6.html @@ -0,0 +1,37 @@ +<div class="typo3-message {f:if(condition:'{preset.isAvailable}', then:'message-ok', else:'message-error')}"> + <div class="header-container"> + <div class="message-header"> + <input + type="radio" + class="t3-install-tool-configuration-radio" + id="t3-install-tool-configuration-image-imagemagick6" + name="install[values][{feature.name}][enable]" + value="{preset.name}" + {f:if(condition:'{preset.isAvailable}', then:'', else:'disabled="disabled"')} + {f:if(condition:'{preset.isActive}', then:'checked="checked"')} + /> + <label + for="t3-install-tool-configuration-image-imagemagick6" + class="t3-install-tool-configuration-radio-label" + > + <strong> + Image Magick version 6 or higher + </strong> + {f:if(condition:'{preset.isActive}', then:' [Active]')} + </label> + </div> + </div> + <div class="message-body>"> + <f:if condition="{preset.isAvailable}"> + <f:then> + An ImageMagick version 6 or higher was found in path {preset.foundPath} + </f:then> + <f:else> + ImageMagick version 6 or higher was not found in standard system paths. + If it is installed at an unusual location at your system, add the path + to the input box above and search again. + </f:else> + </f:if> + </div> +</div> +<p></p> \ No newline at end of file diff --git a/typo3/sysext/install/Resources/Private/Templates/Action/Tool/Configuration.html b/typo3/sysext/install/Resources/Private/Templates/Action/Tool/Configuration.html new file mode 100644 index 0000000000000000000000000000000000000000..aa32bb9aa07c6dba2b35c56b6411069bcc00d625 --- /dev/null +++ b/typo3/sysext/install/Resources/Private/Templates/Action/Tool/Configuration.html @@ -0,0 +1,28 @@ +{namespace i=TYPO3\CMS\Install\ViewHelpers} + +<f:layout name="ToolAuthenticated" /> + +<f:section name="Content"> + <h3>Configuration presets</h3> + + <f:for each="{actionMessages}" as="statusMessage"> + <f:render partial="Action/Common/StatusMessage" arguments="{message: statusMessage}" /> + </f:for> + + <p> + The configuration module suggests best matching configuration settings + based on your system setup. + </p> + + <hr /> + + <form method="post"> + <f:render partial="Action/Common/HiddenFormFields" arguments="{_all}" /> + + <f:for each="{features}" as="feature"> + <f:render partial="Action/Tool/Configuration/{feature.name}" arguments="{_all}" /> + </f:for> + + <f:render partial="Action/Common/SubmitButton" arguments="{name:'activate', text:'Activate'}"/> + </form> +</f:section> \ No newline at end of file diff --git a/typo3/sysext/install/Resources/Public/Images/Menu/Configuration.png b/typo3/sysext/install/Resources/Public/Images/Menu/Configuration.png new file mode 100644 index 0000000000000000000000000000000000000000..3262767cda95a217ac8d3fabf6c4bfe3514fd770 Binary files /dev/null and b/typo3/sysext/install/Resources/Public/Images/Menu/Configuration.png differ diff --git a/typo3/sysext/install/Resources/Public/Stylesheets/Action/Common/Install.css b/typo3/sysext/install/Resources/Public/Stylesheets/Action/Common/Install.css index c415fcdc22db7c51f1f36ca18451423c54a8da94..1ee279e450ea39cbfb784b8f54113ebebc27d146 100755 --- a/typo3/sysext/install/Resources/Public/Stylesheets/Action/Common/Install.css +++ b/typo3/sysext/install/Resources/Public/Stylesheets/Action/Common/Install.css @@ -312,6 +312,10 @@ button span.t3-install-form-button-icon-negative { background-image: url('../../../Images/Menu/SystemEnvironment.png'); } +#t3-install-menu #t3-install-menu-configuration { + background-image: url('../../../Images/Menu/Configuration.png'); +} + #t3-install-menu #t3-install-menu-folderStructure { background-image: url('../../../Images/Menu/FolderStructure.png'); } @@ -398,7 +402,12 @@ button span.t3-install-form-button-icon-negative { color: #111 !important; } - +.t3-install-tool-configuration-radio { + float: none; +} +.t3-install-tool-configuration-radio-label { + float: none; +} .typo3-message { padding: 0.6em 0.6em 0.6em 2.6em; @@ -632,4 +641,4 @@ body.standalone .t3-install-login h2 { clear: both; margin: 0; padding: 0.5em 0 0.5em 3.35em; -} +} \ No newline at end of file