g(2030));
echo "
";
if( isset($fromAuto) && $fromAuto==true){
msg_info($l->g(2031)." ".$valUpd["tvalue"]." ".$l->g(2032)." (" . GUI_VER . "). ".$l->g(2033));
}
if( isset($fromdbconfig_out) && $fromdbconfig_out==true)
msg_info($l->g(2034));
if(!function_exists('session_start')) {
msg_error($l->g(2035));
die();
}
if(!function_exists('mysql_connect')) {
msg_error($l->g(2037));
die();
}
$warning_lbl='';
if(!function_exists('xml_parser_create')) {
$warning_lbl.=$l->g(2036)."
";
}
if(!function_exists('imagefontwidth')) {
$warning_lbl.=$l->g(2038)."
";
}
if(!function_exists('openssl_open')) {
$warning_lbl.=$l->g(2039)."
";
}
if ($warning_lbl != '')
msg_warning($warning_lbl);
$pms = "post_max_size";
$umf = "upload_max_filesize";
$valTpms = ini_get( $pms );
$valTumf = ini_get( $umf );
$valBpms = return_bytes( $valTpms );
$valBumf = return_bytes( $valTumf );
if( $valBumf>$valBpms )
$MaxAvail = trim(mb_strtoupper($valTpms),"M");
else
$MaxAvail = trim(mb_strtoupper($valTumf),"M");
if( isset($_POST["name"])) {
$link=dbconnect($_POST["host"],$_POST["name"],$_POST["pass"],$_POST["database"]);
if(!is_resource($link) and $link != 'NO_DATABASE'){
$firstAttempt=false;
msg_error($l->g(2001)." ".$l->g(249).
" (".$l->g(2010)."=".$_POST["host"].
" ".$l->g(2011)."=".$_POST["name"].
" ".$l->g(2014)."=".$_POST["pass"].
")
".$link);
}
else
$instOk = true;
}
if( $hnd = @fopen(CONF_MYSQL, "r") ) {
fclose($hnd);
require(CONF_MYSQL);
if (defined('COMPTE_BASE')) { // Upgrade from 2.0.x
$valNme = COMPTE_BASE;
} else if (isset($_SESSION["COMPTE_BASE"])) { // Upgrade from 1.3.x
$valNme = $_SESSION["COMPTE_BASE"];
} else { // Fresh install
$valNme = '';
}
if (defined('PSWD_BASE')) {
$valPass = PSWD_BASE;
} else if (isset($_SESSION["PSWD_BASE"])) {
$valPass = $_SESSION["PSWD_BASE"];
} else {
$valPass = '';
}
if (defined('SERVER_WRITE')) {
$valServ = SERVER_WRITE;
} else if (isset($_SESSION["SERVEUR_SQL"])) {
$valServ = $_SESSION["SERVEUR_SQL"];
} else {
$valServ = '';
}
if (defined('DB_NAME')) {
$valdatabase = DB_NAME;
} else { // Upgrade from 1.3.x
$valdatabase = 'ocsweb';
}
}
if( ! $instOk ) {
require_once('require/function_table_html.php');
msg_info($l->g(2040) . " " . $MaxAvail . $l->g(1240) . "
" . $l->g(2041)."
".$l->g(2102)."");
$form_name='fsub';
//echo "