modify setup for CL 2.1

Dieser Commit ist enthalten in:
Oldperl 2019-11-04 14:55:28 +00:00
Ursprung 15bcdb5600
Commit e3ace87155
5 geänderte Dateien mit 48 neuen und 50 gelöschten Zeilen

Datei anzeigen

@ -52,7 +52,7 @@ if (checkMySQLDatabaseCreation($db, $_SESSION['dbname'])) {
$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
$file = fopen('data/tables.txt', 'r');
@ -81,29 +81,33 @@ while (($data = fgetcsv($file, 4000, ';')) !== false) {
}
// Count DB Chunks (plugins)
$file = fopen('data/tables_pi.txt', 'r');
$step = 1;
while (($data = fgetcsv($file, 4000, ';')) !== false) {
if ($count == 50) {
$count = 1;
$step++;
}
if (cFileHandler::exists('data/tables_pi.txt')) {
$file = fopen('data/tables_pi.txt', 'r');
if ($file) {
$step = 1;
while (($data = fgetcsv($file, 4000, ';')) !== false) {
if ($count == 50) {
$count = 1;
$step++;
}
if ($currentstep == $step) {
if ($data[7] == '1') {
$drop = true;
} else {
$drop = false;
}
dbUpgradeTable($db, $_SESSION['dbprefix'] . '_' . $data[0], $data[1], $data[2], $data[3], $data[4], $data[5], $data[6], '', $drop);
if ($currentstep == $step) {
if ($data[7] == '1') {
$drop = true;
} else {
$drop = false;
}
dbUpgradeTable($db, $_SESSION['dbprefix'] . '_' . $data[0], $data[1], $data[2], $data[3], $data[4], $data[5], $data[6], '', $drop);
if ($db->errno != 0) {
$_SESSION['install_failedupgradetable'] = true;
if ($db->errno != 0) {
$_SESSION['install_failedupgradetable'] = true;
}
}
$count++;
$fullcount++;
}
}
$count++;
$fullcount++;
}
$pluginChunks = array();
@ -120,24 +124,6 @@ $contentChunks = txtFileToArray('data/examples.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') {
switch ($_SESSION['clientmode']) {
case 'CLIENT':
@ -259,10 +245,10 @@ if ($currentstep < $totalsteps) {
$aSqlArray = $db->getProfileData();
if (is_array($aSqlArray) && count($aSqlArray) > 0) {
$fp = fopen('../data/logs/setup_queries.txt', 'w');
foreach ($aSqlArray as $failedChunk) {
fwrite($fp, print_r($aSqlArray, TRUE));
}
fclose($fp);
foreach ($aSqlArray as $failedChunk) {
fwrite($fp, print_r($aSqlArray, TRUE));
}
fclose($fp);
}
printf('<script type="text/javascript">parent.document.getElementById("installing").style.visibility="hidden";parent.document.getElementById("installingdone").style.visibility="visible";</script>');

Datei anzeigen

@ -57,5 +57,5 @@ define('C_SETUP_STEPFILE_ACTIVE', 'images/steps/s%da.png');
define('C_SETUP_STEPWIDTH', 28);
define('C_SETUP_STEPHEIGHT', 28);
define('C_SETUP_MIN_PHP_VERSION', '5.6');
define('C_SETUP_VERSION', '2.1.0');
define('C_SETUP_VERSION', '2.1.1');
?>

Datei anzeigen

@ -59,8 +59,8 @@ class cSetupAdditionalPlugins extends cSetupMask {
// add new plugins to this array and you're done.
$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_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_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'));
$sCheckBoxes = '';
if (sizeof($aPlugins) > 0) {

Datei anzeigen

@ -41,17 +41,26 @@ class cSetupClientMode extends cSetupMask {
cInitializeArrayKey($_SESSION, "clientmode", "");
$aChoices = array("CLIENTEXAMPLES" => i18n_setup("Client with example modules and example content"),
"CLIENTMODULES" => i18n_setup("Client with example modules, but without example content"),
"CLIENT" => i18n_setup("Client without examples"),
"NOCLIENT" => i18n_setup("Don't create client"));
$aChoices = array();
$aChoices["CLIENTEXAMPLES"] = "none"; //i18n_setup("Client with example modules and example content");
$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) {
if ($sChoice == "none") {
$this->_oStepTemplate->set("s", "CONTROL_" . $sKey, "");
$this->_oStepTemplate->set("s", "LABEL_" . $sKey, "");
continue;
}
$oRadio = new cHTMLRadiobutton("clientmode", $sKey);
$oRadio->setLabelText(" ");
$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");
}

Datei anzeigen

@ -446,6 +446,9 @@ class cSetupSystemtest extends cSetupMask {
}
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
if ($_SESSION["setuptype"] != "setup") {
// old folders