modify setup for CL 2.1
Dieser Commit ist enthalten in:
Ursprung
15bcdb5600
Commit
e3ace87155
|
@ -52,7 +52,7 @@ if (checkMySQLDatabaseCreation($db, $_SESSION['dbname'])) {
|
||||||
$db = getSetupMySQLDBConnection();
|
$db = getSetupMySQLDBConnection();
|
||||||
}
|
}
|
||||||
|
|
||||||
$currentstep = (empty($_GET['step']))?1:filter_input(INPUT_GET, "step", FILTER_SANITIZE_NUMBER_INT);
|
$currentstep = (empty($_GET['step'])) ? 1 : filter_input(INPUT_GET, "step", FILTER_SANITIZE_NUMBER_INT);
|
||||||
|
|
||||||
// Count DB Chunks
|
// Count DB Chunks
|
||||||
$file = fopen('data/tables.txt', 'r');
|
$file = fopen('data/tables.txt', 'r');
|
||||||
|
@ -81,29 +81,33 @@ while (($data = fgetcsv($file, 4000, ';')) !== false) {
|
||||||
}
|
}
|
||||||
|
|
||||||
// Count DB Chunks (plugins)
|
// Count DB Chunks (plugins)
|
||||||
$file = fopen('data/tables_pi.txt', 'r');
|
if (cFileHandler::exists('data/tables_pi.txt')) {
|
||||||
$step = 1;
|
$file = fopen('data/tables_pi.txt', 'r');
|
||||||
while (($data = fgetcsv($file, 4000, ';')) !== false) {
|
if ($file) {
|
||||||
if ($count == 50) {
|
$step = 1;
|
||||||
$count = 1;
|
while (($data = fgetcsv($file, 4000, ';')) !== false) {
|
||||||
$step++;
|
if ($count == 50) {
|
||||||
}
|
$count = 1;
|
||||||
|
$step++;
|
||||||
|
}
|
||||||
|
|
||||||
if ($currentstep == $step) {
|
if ($currentstep == $step) {
|
||||||
if ($data[7] == '1') {
|
if ($data[7] == '1') {
|
||||||
$drop = true;
|
$drop = true;
|
||||||
} else {
|
} else {
|
||||||
$drop = false;
|
$drop = false;
|
||||||
}
|
}
|
||||||
dbUpgradeTable($db, $_SESSION['dbprefix'] . '_' . $data[0], $data[1], $data[2], $data[3], $data[4], $data[5], $data[6], '', $drop);
|
dbUpgradeTable($db, $_SESSION['dbprefix'] . '_' . $data[0], $data[1], $data[2], $data[3], $data[4], $data[5], $data[6], '', $drop);
|
||||||
|
|
||||||
if ($db->errno != 0) {
|
if ($db->errno != 0) {
|
||||||
$_SESSION['install_failedupgradetable'] = true;
|
$_SESSION['install_failedupgradetable'] = true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
$count++;
|
||||||
|
$fullcount++;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
$count++;
|
|
||||||
$fullcount++;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
$pluginChunks = array();
|
$pluginChunks = array();
|
||||||
|
@ -120,24 +124,6 @@ $contentChunks = txtFileToArray('data/examples.txt');
|
||||||
|
|
||||||
$sysadminChunk = txtFileToArray('data/sysadmin.txt');
|
$sysadminChunk = txtFileToArray('data/sysadmin.txt');
|
||||||
|
|
||||||
/*
|
|
||||||
if ($_SESSION['plugin_newsletter'] == 'true') {
|
|
||||||
$newsletter = txtFileToArray('data/plugin_newsletter.txt');
|
|
||||||
$pluginChunks = array_merge($pluginChunks, $newsletter);
|
|
||||||
}
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
|
|
||||||
if ($_SESSION['plugin_content_allocation'] == 'true') {
|
|
||||||
$content_allocation = txtFileToArray('data/plugin_content_allocation.txt');
|
|
||||||
$pluginChunks = array_merge($pluginChunks, $content_allocation);
|
|
||||||
}
|
|
||||||
|
|
||||||
if ($_SESSION['plugin_mod_rewrite'] == 'true') {
|
|
||||||
$mod_rewrite = txtFileToArray('data/plugin_mod_rewrite.txt');
|
|
||||||
$pluginChunks = array_merge($pluginChunks, $mod_rewrite);
|
|
||||||
}
|
|
||||||
|
|
||||||
if ($_SESSION['setuptype'] == 'setup') {
|
if ($_SESSION['setuptype'] == 'setup') {
|
||||||
switch ($_SESSION['clientmode']) {
|
switch ($_SESSION['clientmode']) {
|
||||||
case 'CLIENT':
|
case 'CLIENT':
|
||||||
|
@ -259,10 +245,10 @@ if ($currentstep < $totalsteps) {
|
||||||
$aSqlArray = $db->getProfileData();
|
$aSqlArray = $db->getProfileData();
|
||||||
if (is_array($aSqlArray) && count($aSqlArray) > 0) {
|
if (is_array($aSqlArray) && count($aSqlArray) > 0) {
|
||||||
$fp = fopen('../data/logs/setup_queries.txt', 'w');
|
$fp = fopen('../data/logs/setup_queries.txt', 'w');
|
||||||
foreach ($aSqlArray as $failedChunk) {
|
foreach ($aSqlArray as $failedChunk) {
|
||||||
fwrite($fp, print_r($aSqlArray, TRUE));
|
fwrite($fp, print_r($aSqlArray, TRUE));
|
||||||
}
|
}
|
||||||
fclose($fp);
|
fclose($fp);
|
||||||
}
|
}
|
||||||
|
|
||||||
printf('<script type="text/javascript">parent.document.getElementById("installing").style.visibility="hidden";parent.document.getElementById("installingdone").style.visibility="visible";</script>');
|
printf('<script type="text/javascript">parent.document.getElementById("installing").style.visibility="hidden";parent.document.getElementById("installingdone").style.visibility="visible";</script>');
|
||||||
|
|
|
@ -57,5 +57,5 @@ define('C_SETUP_STEPFILE_ACTIVE', 'images/steps/s%da.png');
|
||||||
define('C_SETUP_STEPWIDTH', 28);
|
define('C_SETUP_STEPWIDTH', 28);
|
||||||
define('C_SETUP_STEPHEIGHT', 28);
|
define('C_SETUP_STEPHEIGHT', 28);
|
||||||
define('C_SETUP_MIN_PHP_VERSION', '5.6');
|
define('C_SETUP_MIN_PHP_VERSION', '5.6');
|
||||||
define('C_SETUP_VERSION', '2.1.0');
|
define('C_SETUP_VERSION', '2.1.1');
|
||||||
?>
|
?>
|
|
@ -59,8 +59,8 @@ class cSetupAdditionalPlugins extends cSetupMask {
|
||||||
// add new plugins to this array and you're done.
|
// add new plugins to this array and you're done.
|
||||||
$aPlugins = array();
|
$aPlugins = array();
|
||||||
//$aPlugins['plugin_newsletter'] = array('label' => i18n_setup('Newsletter'), 'desc' => i18n_setup('Newsletterfunctionality for dispatching text newsletters and HTML-Newsletters, extensible with professional newsletter extensions. Definition of newsletter recipients and groups of recipients. Layout design of the HTML-Newsletters by ConLite articles.'));
|
//$aPlugins['plugin_newsletter'] = array('label' => i18n_setup('Newsletter'), 'desc' => i18n_setup('Newsletterfunctionality for dispatching text newsletters and HTML-Newsletters, extensible with professional newsletter extensions. Definition of newsletter recipients and groups of recipients. Layout design of the HTML-Newsletters by ConLite articles.'));
|
||||||
$aPlugins['plugin_content_allocation'] = array('label' => i18n_setup('Content Allocation'), 'desc' => i18n_setup('For the representation and administration of content, 4fb developed the Content Allocation and content include technology. This technology dynamically allows on basis of a Template, to put the content in different places and in different formats according to several criteria.'));
|
//$aPlugins['plugin_content_allocation'] = array('label' => i18n_setup('Content Allocation'), 'desc' => i18n_setup('For the representation and administration of content, 4fb developed the Content Allocation and content include technology. This technology dynamically allows on basis of a Template, to put the content in different places and in different formats according to several criteria.'));
|
||||||
$aPlugins['plugin_mod_rewrite'] = array('label' => i18n_setup('Mod Rewrite'), 'desc' => i18n_setup('Creates so called Clean URLs for a ConLite installation'));
|
//$aPlugins['plugin_mod_rewrite'] = array('label' => i18n_setup('Mod Rewrite'), 'desc' => i18n_setup('Creates so called Clean URLs for a ConLite installation'));
|
||||||
|
|
||||||
$sCheckBoxes = '';
|
$sCheckBoxes = '';
|
||||||
if (sizeof($aPlugins) > 0) {
|
if (sizeof($aPlugins) > 0) {
|
||||||
|
|
|
@ -41,17 +41,26 @@ class cSetupClientMode extends cSetupMask {
|
||||||
|
|
||||||
cInitializeArrayKey($_SESSION, "clientmode", "");
|
cInitializeArrayKey($_SESSION, "clientmode", "");
|
||||||
|
|
||||||
$aChoices = array("CLIENTEXAMPLES" => i18n_setup("Client with example modules and example content"),
|
$aChoices = array();
|
||||||
"CLIENTMODULES" => i18n_setup("Client with example modules, but without example content"),
|
|
||||||
"CLIENT" => i18n_setup("Client without examples"),
|
$aChoices["CLIENTEXAMPLES"] = "none"; //i18n_setup("Client with example modules and example content");
|
||||||
"NOCLIENT" => i18n_setup("Don't create client"));
|
$aChoices["CLIENTMODULES"] = "none"; //i18n_setup("Client with example modules, but without example content");
|
||||||
|
$aChoices["CLIENT"] = i18n_setup("Client without examples");
|
||||||
|
$aChoices["NOCLIENT"] = i18n_setup("Don't create client");
|
||||||
|
|
||||||
|
$sChoiceDefault = "CLIENTEXAMPLES";
|
||||||
|
|
||||||
foreach ($aChoices as $sKey => $sChoice) {
|
foreach ($aChoices as $sKey => $sChoice) {
|
||||||
|
if ($sChoice == "none") {
|
||||||
|
$this->_oStepTemplate->set("s", "CONTROL_" . $sKey, "");
|
||||||
|
$this->_oStepTemplate->set("s", "LABEL_" . $sKey, "");
|
||||||
|
continue;
|
||||||
|
}
|
||||||
$oRadio = new cHTMLRadiobutton("clientmode", $sKey);
|
$oRadio = new cHTMLRadiobutton("clientmode", $sKey);
|
||||||
$oRadio->setLabelText(" ");
|
$oRadio->setLabelText(" ");
|
||||||
$oRadio->setStyle('width:auto;border:0;');
|
$oRadio->setStyle('width:auto;border:0;');
|
||||||
|
|
||||||
if ($_SESSION["clientmode"] == $sKey || ($_SESSION["clientmode"] == "" && $sKey == "CLIENTEXAMPLES")) {
|
if ($_SESSION["clientmode"] == $sKey || ($_SESSION["clientmode"] == "" && $sKey == $sChoiceDefault)) {
|
||||||
$oRadio->setChecked("checked");
|
$oRadio->setChecked("checked");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -446,6 +446,9 @@ class cSetupSystemtest extends cSetupMask {
|
||||||
}
|
}
|
||||||
|
|
||||||
public function doFileSystemTests() {
|
public function doFileSystemTests() {
|
||||||
|
if(!is_readable(CON_SETUP_PATH."/data")) {
|
||||||
|
$this->runTest(false, C_SEVERITY_ERROR, i18n_setup("Setup data folder not readable!"), i18n_setup("Please check the Folder setup/data! Maybe it' s missing or not readable."));
|
||||||
|
}
|
||||||
// old logs
|
// old logs
|
||||||
if ($_SESSION["setuptype"] != "setup") {
|
if ($_SESSION["setuptype"] != "setup") {
|
||||||
// old folders
|
// old folders
|
||||||
|
|
Laden…
In neuem Issue referenzieren