Version ' . MSD_VERSION . '
' . $lang['L_DBPARAMETER'] . '
'; if (!is_writable("config.php")) { echo '' . $lang['L_CONFIGNOTWRITABLE'] . '
'; echo '' . $lang['L_TRYAGAIN'] . ''; echo ' ' . $lang['L_INSTALL_TOMENU'] . ''; } else { $tmp=file("config.php"); $stored=0; if (!isset($_POST['dbconnect'])) { // Erstaufruf - Daten aus config.php auslesen for ($i=0; $i < count($tmp); $i++) { if (substr($tmp[$i],0,17) == '$config[\'dbhost\']') { $config['dbhost']=extractValue($tmp[$i]); $dbhost=$config['dbhost']; $stored++; } if (substr($tmp[$i],0,17) == '$config[\'dbport\']') { $config['dbport']=extractValue($tmp[$i]); $dbport=$config['dbport']; $stored++; } if (substr($tmp[$i],0,19) == '$config[\'dbsocket\']') { $config['dbsocket']=extractValue($tmp[$i]); $dbsocket=$config['dbsocket']; $stored++; } if (substr($tmp[$i],0,17) == '$config[\'dbuser\']') { $config['dbuser']=extractValue($tmp[$i]); $dbuser=$config['dbuser']; $stored++; } if (substr($tmp[$i],0,17) == '$config[\'dbpass\']') { $config['dbpass']=extractValue($tmp[$i]); $dbpass=$config['dbpass']; $stored++; } if (substr($tmp[$i],0,19) == '$config[\'language\']') { $config['language']=extractValue($tmp[$i]); $stored++; } if ($stored == 6) break; } } if (!isset($config['dbport'])) $config['dbport']=""; if (!isset($config['dbsocket'])) $config['dbsocket']=""; echo ''; if ($connection == "ok") { if (!isset($databases['Name'][0])) echo '
' . $lang['L_NO_DB_FOUND_INFO']; echo ''; } } break; case 2: // echo '
MySQLDumper - ' . $lang['L_CONFBASIC'] . '
'; $tmp=@file("config.php"); $stored=0; for ($i=0; $i < count($tmp); $i++) { if (substr($tmp[$i],0,17) == '$config[\'dbhost\']') { $tmp[$i]='$config[\'dbhost\'] = \'' . $dbhost . '\';' . "\n"; $stored++; } if (substr($tmp[$i],0,17) == '$config[\'dbport\']') { $tmp[$i]='$config[\'dbport\'] = \'' . $dbport . '\';' . "\n"; $stored++; } if (substr($tmp[$i],0,19) == '$config[\'dbsocket\']') { $tmp[$i]='$config[\'dbsocket\'] = \'' . $dbsocket . '\';' . "\n"; $stored++; } if (substr($tmp[$i],0,17) == '$config[\'dbuser\']') { $tmp[$i]='$config[\'dbuser\'] = \'' . $dbuser . '\';' . "\n"; $stored++; } if (substr($tmp[$i],0,17) == '$config[\'dbpass\']') { $tmp[$i]='$config[\'dbpass\'] = \'' . $dbpass . '\';' . "\n"; $stored++; } if ($stored == 6) break; } $ret=true; if ($fp=fopen("config.php","wb")) { if (!fwrite($fp,implode($tmp,""))) $ret=false; if (!fclose($fp)) $ret=false; @chmod("config.php",0644); } if (!$ret) { echo '' . $lang['L_CONFIG_SAVE_ERROR'] . '
'; } else { if (ini_get('safe_mode') == 1) { $nextphase=( extension_loaded("ftp") ) ? 10 : 9; } else $nextphase=$phase + 2; echo $lang['L_INSTALL_STEP2FINISHED']; echo ''; echo ''; echo ''; } break; case 3: // if (ini_get('safe_mode') == 1) $nextphase=10; else $nextphase=$phase + 1; echo '
' . $lang['L_EDITCONF'] . '
'; echo ''; break; case 4: //Verzeichnisse if (isset($_POST['submit'])) { $ret=true; if ($fp=fopen("config.php","wb")) { if (!fwrite($fp,stripslashes(stripslashes($_POST['configfile'])))) $ret=false; if (!fclose($fp)) $ret=false; } else $ret=false; if ($ret == false) { echo '' . $lang['L_ERRORMAN'] . ' config.php ' . $lang['L_MANUELL'] . '.'; die(); } } echo '
' . $lang['L_CREATEDIRS'] . '
'; $check_dirs=ARRAY( "work/", "work/config/", "work/log/", "work/backup/" ); $msg=''; foreach ($check_dirs as $d) { $success=SetFileRechte($d,1,0777); if ($success != 1) $msg.=$success . ''; } if ($msg > '') echo '' . $msg . ''; $iw[0]=IsWritable("work"); $iw[1]=IsWritable("work/config"); $iw[2]=IsWritable("work/log"); $iw[3]=IsWritable("work/backup"); // save manual_db if ($manual_db > '') { if (file_exists('./' . $config['files']['dbs_manual'])) @unlink('./' . $config['files']['dbs_manual']); $file_handle=fopen('./' . $config['files']['dbs_manual'],'a'); if ($file_handle) { fwrite($file_handle,$manual_db); fclose($file_handle); @chmod('./' . $config['files']['dbs_manual'],0777); } } if ($iw[0] && $iw[1] && $iw[2] && $iw[3]) { echo ''; } echo ''; break; case 5: echo '
' . $lang['L_LASTSTEP'] . '
'; echo '' . $lang['L_INSTALLFINISHED'] . '
'; SetDefault(1); include ( "language/" . $language . "/lang_install.php" ); // direkt zum Start des Dumeprs echo ''; break; case 9: clearstatcache(); $iw[0]=IsWritable("work"); $iw[1]=IsWritable("work/config"); $iw[2]=IsWritable("work/log"); $iw[3]=IsWritable("work/backup"); echo '' . $lang['L_FTPMODE'] . '
'; echo '' . $lang['L_SAFEMODEDESC'] . '
'; echo ''; if (isset($ftp_connect)) { echo ''; $tftp=TesteFTP($install_ftp_server,$install_ftp_port,$install_ftp_user_name,$install_ftp_user_pass,$install_ftp_path); echo $tftp; echo ' | '; if (substr($tftp,-9) == "") { echo ''; } echo ' |
' . $lang['L_FTPMODE'] . '
'; if (CreateDirsFTP() == 1) { SetDefault(true); echo DirectoryWarnings(); echo '' . $lang['L_INSTALLFINISHED']; } break; case 100: //uninstall echo '
' . $lang['L_UI1'] . '
'; echo '' . $lang['L_UI2'] . '
'; echo '' . $lang['L_UI3'] . ' '; echo '' . $lang['L_UI4'] . ''; break; case 101: echo '' . $lang['L_UI5'] . '
'; $paths=Array(); $w=substr($config['paths']['work'],0,strlen($config['paths']['work']) - 1); if (is_dir($w)) $res=rec_rmdir($w); else $res=0; // wurde das Verzeichnis korrekt gelöscht if ($res == 0) { // das Verzeichnis wurde korrekt gelöscht echo '' . $lang['L_UI6'] . '
'; echo $lang['L_UI7'] . "\"" . Realpfad("./") . "\"
" . $lang['L_MANUELL'] . ".
"; echo '' . $lang['L_UI8'] . ''; } else { echo '
' . $lang['L_UI9'] . '"' . $paths[count($paths) - 1] . '"'; } break; } ?>