il codice è molto lungo, te lo posto in piu parti: Parte1
il codice di index.php relativo all'installazione è questo
Codice PHP:
<?php
if (function_exists('date_default_timezone_set'))
date_default_timezone_set('Europe/Paris');
/* Redefine REQUEST_URI if empty (on some webservers...) */
if (!isset($_SERVER['REQUEST_URI']) || $_SERVER['REQUEST_URI'] == '')
$_SERVER['REQUEST_URI'] = $_SERVER['SCRIPT_NAME'];
if ($tmp = strpos($_SERVER['REQUEST_URI'], '?'))
$_SERVER['REQUEST_URI'] = substr($_SERVER['REQUEST_URI'], 0, $tmp);
define('INSTALL_VERSION', '1.1.0.5');
define('MINIMUM_VERSION_TO_UPDATE', '0.8.5');
define('INSTALL_PATH', dirname(__FILE__));
define('PS_BASE_URI', substr($_SERVER['REQUEST_URI'], 0, -1 * (strlen($_SERVER['REQUEST_URI']) - strrpos($_SERVER['REQUEST_URI'], '/')) - strlen(substr(substr($_SERVER['REQUEST_URI'],0,-1), strrpos( substr($_SERVER['REQUEST_URI'],0,-1),"/" )+1))));
define('PS_BASE_URI_ABSOLUTE', 'http://'.htmlspecialchars($_SERVER["HTTP_HOST"], ENT_COMPAT, 'UTF-8').PS_BASE_URI);
/* Old version detection */
$oldversion = false;
$sameVersions = false;
$tooOld = true;
if(file_exists(INSTALL_PATH.'/../config/settings.inc.php')){
include(INSTALL_PATH.'/../config/settings.inc.php');
$oldversion =_PS_VERSION_;
$tooOld = (version_compare($oldversion, MINIMUM_VERSION_TO_UPDATE) == -1);
$sameVersions = (version_compare($oldversion, INSTALL_VERSION) == 0);
}
include(INSTALL_PATH.'/classes/LanguagesManager.php');
$lm = new LanguageManager(dirname(__FILE__).'/langs/list.xml');
$_LANG = array();
$_LIST_WORDS = array();
function lang($txt) {
global $_LANG , $_LIST_WORDS;
return (isset($_LANG[$txt]) ? $_LANG[$txt] : $txt);
}
if ($lm->getIncludeTradFilename())
include_once($lm->getIncludeTradFilename());
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" >
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<title><?php echo lang('PrestaShop '.INSTALL_VERSION.' Installer')?></title>
<link rel="stylesheet" type="text/css" media="all" href="view.css"/>
<script type="text/javascript" src="../js/jquery/jquery-1.2.6.pack.js"></script>
<script type="text/javascript" src="../js/jquery/ajaxfileupload.js"></script>
<script type="text/javascript" src="../js/jquery/jquery.pngFix.pack.js"></script>
<script type="text/javascript" src="../js/jquery/jqminmax-compressed.js"></script>
<link rel="shortcut icon" href="../img/favicon.ico" />
<script type="text/javascript">
//php to js vars
var isoCodeLocalLanguage = "<?php echo $lm->getIsoCodeSelectedLang()?>";
var ps_base_uri = "<?php echo PS_BASE_URI?>";
//localWords
var Step1Title = "<?php echo lang('Welcome').' - '.lang('PrestaShop '.INSTALL_VERSION.' Installer'); ?>";
var step2title = "<?php echo lang('System compatibility').' - '.lang('PrestaShop '.INSTALL_VERSION.' Installer'); ?>";
var step3title = "<?php echo lang('System configuration').' - '.lang('PrestaShop '.INSTALL_VERSION.' Installer'); ?>";
var step4title = "<?php echo lang('Shop configuration').' - '.lang('PrestaShop '.INSTALL_VERSION.' Installer'); ?>";
var step5title = "<?php echo lang('Ready, set, go!').' - '.lang('PrestaShop '.INSTALL_VERSION.' Installer'); ?>";
var step6title = "<?php echo lang('Disclaimer').' - '.lang('PrestaShop '.INSTALL_VERSION.' Installer'); ?>";
var step7title = "<?php echo lang('System compatibility').' - '.lang('PrestaShop '.INSTALL_VERSION.' Installer'); ?>";
var step8title = "<?php echo lang('Errors while updating...').' - '.lang('PrestaShop '.INSTALL_VERSION.' Installer'); ?>";
var step9title = "<?php echo lang('Ready, set, go!').' - '.lang('PrestaShop '.INSTALL_VERSION.' Installer'); ?>";
var txtNext = "<?php echo lang('Next')?>"
var txtDbLoginEmpty = "<?php echo lang('Please set a database login'); ?>";
var txtDbNameEmpty = "<?php echo lang('Please set a database name'); ?>";
var txtDbServerEmpty = "<?php echo lang('Please set a database server name'); ?>";
var txtSmtpAvailable = "<?php echo lang('SMTP connection is available!'); ?>";
var txtSmtpError = "<?php echo lang('SMTP connection is unavailable'); ?>";
var txtSmtpSrvEmpty = "<?php echo lang('Please set a SMTP server name'); ?>";
var txtSmtpLoginEmpty = "<?php echo lang('Please set a SMTP login'); ?>";
var txtSmtpPasswordEmpty = "<?php echo lang('Please set a SMTP password'); ?>";
var txtNativeMailAvailable = "<?php echo lang('PHP \'mail()\' function is available'); ?>";
var txtNativeMailError = "<?php echo lang('PHP \'mail()\' function is unavailable'); ?>";
var txtDbCreated = "<?php echo lang('Database is created!'); ?>";
var testMsg = "<?php echo lang('This is a test message, your server is now available to send email'); ?>";
var testSubject = "<?php echo lang('Test message - Prestashop'); ?>";
var mailSended = "<?php echo lang('An email has been sent!'); ?>";
var mailSubject = "<?php echo lang('Congratulation, your online shop is now ready!'); ?>";
var txtTabUpdater1 = "<?php echo lang('Welcome'); ?>";
var txtTabUpdater2 = "<?php echo lang('Disclaimer'); ?>";
var txtTabUpdater3 = "<?php echo lang('Verify system compatibility'); ?>";
var txtTabUpdater4 = "<?php echo lang('Update is complete!'); ?>";
var txtTabInstaller1 = "<?php echo lang('Welcome'); ?>";
var txtTabInstaller2 = "<?php echo lang('Verify system compatibility'); ?>";
var txtTabInstaller3 = "<?php echo lang('System configuration'); ?>";
var txtTabInstaller4 = "<?php echo lang('Shop configuration'); ?>";
var txtTabInstaller5 = "<?php echo lang('Installation is complete!'); ?>";
var txtError = new Array();
txtError[0] = "<?php echo lang('Required field'); ?>";
txtError[1] = "<?php echo lang('Too long!'); ?>";
txtError[2] = "<?php echo lang('Fields are different!'); ?>";
txtError[3] = "<?php echo lang('This email adress is wrong!'); ?>";
txtError[4] = "<?php echo lang('Impossible to send the email!'); ?>";
txtError[5] = "<?php echo lang('Can\'t create settings file, if /config/settings.inc.php exists, please give the public write permissions to this file, else please create a file named settings.inc.php in config directory.'); ?>";
txtError[6] = "<?php echo lang('Can\'t write settings file, please create a file named settings.inc.php in config directory.'); ?>";
txtError[7] = "<?php echo lang('Impossible to upload the file!'); ?>";
txtError[8] = "<?php echo lang('Data integrity is not valided. Hack attempt ?'); ?>";
txtError[9] = "<?php echo lang('Impossible the read the content of a MySQL content file.'); ?>";
txtError[10] = "<?php echo lang('Impossible the access the a MySQL content file.'); ?>";
txtError[11] = "<?php echo lang('Error while inserting data in the database:'); ?>";
txtError[12] = "<?php echo lang('The password is incorrect (alphanumeric string at least 8 characters).'); ?>";
txtError[14] = "<?php echo lang('A Prestashop database already exists, please drop it or change the prefix.'); ?>";
txtError[15] = "<?php echo lang('This is not a valid file name.'); ?>";
txtError[16] = "<?php echo lang('This is not a valid image file.'); ?>";
txtError[17] = "<?php echo lang('Error while creating the /config/settings.inc.php file.'); ?>";
txtError[18] = "<?php echo lang('Error:'); ?>";
txtError[19] = "<?php echo lang('This PrestaShop database already exists. Please revalidate your authentication informations to the database.'); ?>";
txtError[22] = "<?php echo lang('An error occured while resizing the picture.'); ?>";
txtError[23] = "<?php echo lang('Database connection is available!'); ?>";
txtError[24] = "<?php echo lang('Database Server is available but database is not found'); ?>";
txtError[25] = "<?php echo lang('Database Server is not found. Please verify the login, password and server fields.'); ?>";
txtError[26] = "<?php echo lang('An error occured while sending email, please verify your parameters.'); ?>";
txtError[37] = "<?php echo lang('Impossible to write the image /img/logo.jpg. If this image already exists, please delete it.'); ?>";
txtError[38] = "<?php echo lang('The uploaded file exceeds the upload_max_filesize directive in php.ini'); ?>";
txtError[39] = "<?php echo lang('The uploaded file exceeds the MAX_FILE_SIZE directive that was specified in the HTML form'); ?>";
txtError[40] = "<?php echo lang('The uploaded file was only partially uploaded'); ?>";
txtError[41] = "<?php echo lang('No file was uploaded.'); ?>";
txtError[42] = "<?php echo lang('Missing a temporary folder'); ?>";
txtError[43] = "<?php echo lang('Failed to write file to disk'); ?>";
txtError[44] = "<?php echo lang('File upload stopped by extension'); ?>";
txtError[45] = "<?php echo lang('Cannot convert your database\'s data to utf-8.'); ?>";
txtError[999] = "<?php echo lang('No error code available.'); ?>";
//upgrader
txtError[27] = "<?php echo lang('This installer is too old.'); ?>";
txtError[28] = "<?php echo lang('You already have the '.INSTALL_VERSION.' version.'); ?>";
txtError[29] = "<?php echo lang('There is no older version. Did you delete or rename the config/settings.inc.php file ?'); ?>";
txtError[30] = "<?php echo lang('The config/settings.inc.php file was not found. Did you delete or rename this file ?'); ?>";
txtError[31] = "<?php echo lang('Can\'t find the sql upgrade files. Please verify that the /install/sql/upgrade folder is not empty)'); ?>";
txtError[32] = "<?php echo lang('No upgrade is possible.'); ?>";
txtError[33] = "<?php echo lang('Error while loading sql upgrade file.'); ?>";
txtError[34] = "<?php echo lang('Error while inserting content into the database'); ?>";
EDIT:
è questo quello che dicevi? altrimenti non continuo... perche è davvero molto lungo