mirror of
https://github.com/e107inc/e107.git
synced 2025-07-31 11:50:30 +02:00
Install Fixes and datepicker fix for Chrome and Safari
This commit is contained in:
@@ -276,15 +276,17 @@ class e107
|
|||||||
*/
|
*/
|
||||||
public function initInstall($e107_paths, $e107_root_path, $e107_config_override = array())
|
public function initInstall($e107_paths, $e107_root_path, $e107_config_override = array())
|
||||||
{
|
{
|
||||||
|
|
||||||
// Do some security checks/cleanup, prepare the environment
|
// Do some security checks/cleanup, prepare the environment
|
||||||
$this->prepare_request();
|
$this->prepare_request();
|
||||||
|
|
||||||
$this->site_path = "[hash]"; // placeholder
|
//generated from mysql data at stage 5 of install.
|
||||||
|
$this->site_path = isset($e107_config_override['site_path']) ? $e107_config_override['site_path'] : "[hash]"; // placeholder
|
||||||
|
|
||||||
// folder info
|
// folder info
|
||||||
//$this->e107_dirs = $e107_paths;
|
//$this->e107_dirs = $e107_paths;
|
||||||
$this->setDirs($e107_paths, $e107_config_override);
|
$this->setDirs($e107_paths, $e107_config_override);
|
||||||
|
|
||||||
|
|
||||||
// build all paths
|
// build all paths
|
||||||
$this->set_paths();
|
$this->set_paths();
|
||||||
$this->file_path = $this->fix_windows_paths($e107_root_path)."/";
|
$this->file_path = $this->fix_windows_paths($e107_root_path)."/";
|
||||||
|
File diff suppressed because it is too large
Load Diff
@@ -886,6 +886,11 @@ class xmlClass
|
|||||||
foreach($xmlArray['database']['dbTable'] as $val)
|
foreach($xmlArray['database']['dbTable'] as $val)
|
||||||
{
|
{
|
||||||
$table = $val['@attributes']['name'];
|
$table = $val['@attributes']['name'];
|
||||||
|
|
||||||
|
if(!isset($val['item']))
|
||||||
|
{
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
foreach($val['item'] as $item)
|
foreach($val['item'] as $item)
|
||||||
{
|
{
|
||||||
|
43
install_.php
43
install_.php
@@ -145,7 +145,6 @@ if($functions_ok == false)
|
|||||||
|
|
||||||
|
|
||||||
//obsolete $installer_folder_name = 'e107_install';
|
//obsolete $installer_folder_name = 'e107_install';
|
||||||
|
|
||||||
include_once("./{$HANDLERS_DIRECTORY}core_functions.php");
|
include_once("./{$HANDLERS_DIRECTORY}core_functions.php");
|
||||||
include_once("./{$HANDLERS_DIRECTORY}e107_class.php");
|
include_once("./{$HANDLERS_DIRECTORY}e107_class.php");
|
||||||
|
|
||||||
@@ -156,12 +155,21 @@ function check_class($whatever)
|
|||||||
return TRUE;
|
return TRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$override = array();
|
||||||
|
|
||||||
|
if(isset($_POST['previous_steps']))
|
||||||
|
{
|
||||||
|
$tmp = unserialize(base64_decode($_POST['previous_steps']));
|
||||||
|
$override = (isset($tmp['paths']['hash'])) ? array('site_path'=>$tmp['paths']['hash']) : array();
|
||||||
|
unset($tmp);
|
||||||
|
}
|
||||||
|
|
||||||
//$e107_paths = compact('ADMIN_DIRECTORY', 'FILES_DIRECTORY', 'IMAGES_DIRECTORY', 'THEMES_DIRECTORY', 'PLUGINS_DIRECTORY', 'HANDLERS_DIRECTORY', 'LANGUAGES_DIRECTORY', 'HELP_DIRECTORY', 'CACHE_DIRECTORY', 'DOWNLOADS_DIRECTORY', 'UPLOADS_DIRECTORY', 'MEDIA_DIRECTORY', 'LOGS_DIRECTORY', 'SYSTEM_DIRECTORY', 'CORE_DIRECTORY');
|
//$e107_paths = compact('ADMIN_DIRECTORY', 'FILES_DIRECTORY', 'IMAGES_DIRECTORY', 'THEMES_DIRECTORY', 'PLUGINS_DIRECTORY', 'HANDLERS_DIRECTORY', 'LANGUAGES_DIRECTORY', 'HELP_DIRECTORY', 'CACHE_DIRECTORY', 'DOWNLOADS_DIRECTORY', 'UPLOADS_DIRECTORY', 'MEDIA_DIRECTORY', 'LOGS_DIRECTORY', 'SYSTEM_DIRECTORY', 'CORE_DIRECTORY');
|
||||||
$e107_paths = array();
|
$e107_paths = array();
|
||||||
$e107 = e107::getInstance();
|
$e107 = e107::getInstance();
|
||||||
$e107->initInstall($e107_paths, realpath(dirname(__FILE__)));
|
$e107->initInstall($e107_paths, realpath(dirname(__FILE__)), $override);
|
||||||
unset($e107_paths);
|
unset($e107_paths,$override);
|
||||||
|
|
||||||
|
|
||||||
### NEW Register Autoload - do it asap
|
### NEW Register Autoload - do it asap
|
||||||
if(!function_exists('spl_autoload_register'))
|
if(!function_exists('spl_autoload_register'))
|
||||||
@@ -193,6 +201,7 @@ if(isset($_GET['create_tables']))
|
|||||||
}
|
}
|
||||||
|
|
||||||
header('Content-type: text/html; charset=utf-8');
|
header('Content-type: text/html; charset=utf-8');
|
||||||
|
|
||||||
$e_install = new e_install();
|
$e_install = new e_install();
|
||||||
$e_forms = new e_forms();
|
$e_forms = new e_forms();
|
||||||
|
|
||||||
@@ -202,6 +211,8 @@ $e_install->template->SetTag("files_dir_http", e_FILE_ABS);
|
|||||||
|
|
||||||
$e_install->renderPage();
|
$e_install->renderPage();
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set Cookie
|
* Set Cookie
|
||||||
* @param string $name
|
* @param string $name
|
||||||
@@ -457,9 +468,14 @@ class e_install
|
|||||||
{
|
{
|
||||||
$hash = e107::makeSiteHash($this->previous_steps['mysql']['db'],$this->previous_steps['mysql']['prefix']);
|
$hash = e107::makeSiteHash($this->previous_steps['mysql']['db'],$this->previous_steps['mysql']['prefix']);
|
||||||
$this->e107->site_path = $hash;
|
$this->e107->site_path = $hash;
|
||||||
|
|
||||||
|
$this->previous_steps['paths']['hash'] = $hash;
|
||||||
|
|
||||||
|
|
||||||
foreach($this->e107->e107_dirs as $dir => $p)
|
foreach($this->e107->e107_dirs as $dir => $p)
|
||||||
{
|
{
|
||||||
$this->e107->e107_dirs[$dir] = str_replace("[hash]", $hash, $this->e107->e107_dirs[$dir]);
|
$this->e107->e107_dirs[$dir] = str_replace("[hash]", $hash, $this->e107->e107_dirs[$dir]);
|
||||||
|
|
||||||
if(!is_dir($this->e107->e107_dirs[$dir]))
|
if(!is_dir($this->e107->e107_dirs[$dir]))
|
||||||
{
|
{
|
||||||
@mkdir($this->e107->e107_dirs[$dir]);
|
@mkdir($this->e107->e107_dirs[$dir]);
|
||||||
@@ -953,6 +969,9 @@ class e_install
|
|||||||
private function stage_7()
|
private function stage_7()
|
||||||
{
|
{
|
||||||
global $e_forms;
|
global $e_forms;
|
||||||
|
|
||||||
|
$this->e107->e107_dirs['SYSTEM_DIRECTORY'] = str_replace("[hash]",$this->e107->site_path,$this->e107->e107_dirs['SYSTEM_DIRECTORY']);
|
||||||
|
$this->e107->e107_dirs['CACHE_DIRECTORY'] = str_replace("[hash]",$this->e107->site_path,$this->e107->e107_dirs['CACHE_DIRECTORY']);
|
||||||
|
|
||||||
$this->stage = 7;
|
$this->stage = 7;
|
||||||
$this->logLine('Stage 7 started');
|
$this->logLine('Stage 7 started');
|
||||||
@@ -1017,6 +1036,9 @@ class e_install
|
|||||||
$e_forms->add_button("submit", LANINS_035);
|
$e_forms->add_button("submit", LANINS_035);
|
||||||
|
|
||||||
$this->template->SetTag("stage_content", $page.$e_forms->return_form());
|
$this->template->SetTag("stage_content", $page.$e_forms->return_form());
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
$this->logLine('Stage 7 completed');
|
$this->logLine('Stage 7 completed');
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1031,6 +1053,10 @@ class e_install
|
|||||||
{
|
{
|
||||||
|
|
||||||
global $e_forms;
|
global $e_forms;
|
||||||
|
|
||||||
|
$system_dir = str_replace("/".$this->e107->site_path,"",$this->e107->e107_dirs['SYSTEM_DIRECTORY']);
|
||||||
|
$media_dir = str_replace("/".$this->e107->site_path,"",$this->e107->e107_dirs['MEDIA_DIRECTORY']);
|
||||||
|
|
||||||
|
|
||||||
// required for various core routines
|
// required for various core routines
|
||||||
if(!defined('USERNAME'))
|
if(!defined('USERNAME'))
|
||||||
@@ -1046,6 +1072,9 @@ class e_install
|
|||||||
$this->template->SetTag("stage_pre", LANINS_002);
|
$this->template->SetTag("stage_pre", LANINS_002);
|
||||||
$this->template->SetTag("stage_num", LANINS_120);
|
$this->template->SetTag("stage_num", LANINS_120);
|
||||||
$this->template->SetTag("stage_title", LANINS_071);
|
$this->template->SetTag("stage_title", LANINS_071);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
$config_file = "<?php
|
$config_file = "<?php
|
||||||
@@ -1079,10 +1108,10 @@ class e_install
|
|||||||
\$HANDLERS_DIRECTORY = '{$this->e107->e107_dirs['HANDLERS_DIRECTORY']}';
|
\$HANDLERS_DIRECTORY = '{$this->e107->e107_dirs['HANDLERS_DIRECTORY']}';
|
||||||
\$LANGUAGES_DIRECTORY = '{$this->e107->e107_dirs['LANGUAGES_DIRECTORY']}';
|
\$LANGUAGES_DIRECTORY = '{$this->e107->e107_dirs['LANGUAGES_DIRECTORY']}';
|
||||||
\$HELP_DIRECTORY = '{$this->e107->e107_dirs['HELP_DIRECTORY']}';
|
\$HELP_DIRECTORY = '{$this->e107->e107_dirs['HELP_DIRECTORY']}';
|
||||||
\$SYSTEM_DIRECTORY = '{$this->e107->e107_dirs['SYSTEM_DIRECTORY']}';
|
\$MEDIA_DIRECTORY = '{$media_dir}';
|
||||||
\$DOWNLOADS_DIRECTORY = '{$this->e107->e107_dirs['DOWNLOADS_DIRECTORY']}';
|
\$SYSTEM_DIRECTORY = '{$system_dir}';
|
||||||
\$UPLOADS_DIRECTORY = '{$this->e107->e107_dirs['UPLOADS_DIRECTORY']}';
|
|
||||||
\$MEDIA_DIRECTORY = '{$this->e107->e107_dirs['MEDIA_DIRECTORY']}';
|
|
||||||
|
|
||||||
|
|
||||||
";
|
";
|
||||||
|
Reference in New Issue
Block a user