$act = $_GET['act'];
$step = $_GET['step'] ? $_GET['step'] : 1;
$step = $step > 4 ? 1 : $step;
$sqlfile = dirname(__FILE__) . "/easytalk.sql";
$lockfile = '../include/lockstall';
if (file_exists($lockfile)) {
    header("Location: ../index.php");
    exit;
}
include "../include/db_mysql.class.php";
include "../include/template.class.php";
include 'install.func.php';
$options = array('template_dir' => './', 'cache_dir' => './', 'auto_update' => true, 'cache_lifetime' => 0);
$template = Template::getInstance();
$template->setOptions($options);
$s0 = file_writeable("../config.inc.php");
$s1 = dir_writeable("../include/cache");
$s2 = dir_writeable("../attachments/head");
$s3 = dir_writeable("../attachments/usertemplates");
$s4 = dir_writeable("../attachments/photo");
$s5 = dir_writeable("../templates/cache");
$s6 = dir_writeable("../admin/backup");
$s7 = dir_writeable("../admin/templates/cache");
$s8 = dir_writeable("../admin/themetemp");
if (($s0 != 1 || $s1 != 1 || $s2 != 1 || $s3 != 1 || $s4 != 1 || $s5 != 1 || $s6 != 1 || $s7 != 1 || $s8 != 1) && $step != 1) {
    header("location: install.php?step=1");
    exit;
}
if ($action == "checkinstall") {
    $server = $_POST['server'];
    $datauname = $_POST['datauname'];
Beispiel #2
0
      	<?php 
switch ($step) {
    case 1:
        if ($msg) {
            $str = "<p>" . $msg . "</p>";
        }
        if ($nextAccess == 1) {
            $str = "<div id=\"tips\"><div class=\"log\">{$lang['step1ReadLicense']}</div><div class=\"mes\"><div align=\"center\"><textarea style=\"width: 94%; height: 300px;\">" . $lang['step1LicenseInfo'] . "</textarea></div><br /><div align=\"center\"><input type=\"submit\" value=\"{$lang['step1Agree']}\" class=\"inbut1\">    <input type=\"button\" value=\"{$lang['step1Disagree']}\" class=\"inbut\" onclick=\"javascript:window.close();\"></div></div>";
        }
        break;
    case 2:
        $fileConfigAccess = file_writeable($configfile);
        $filelogoAccess = file_writeable($logofile);
        $dirUploadsAccess = file_writeable($uploadsDir);
        $dirDataAccess = file_writeable($dataDir);
        $dirPluginAccess = file_writeable($pluginDir);
        if (@ini_get("file_uploads")) {
            $max_size = @ini_get(upload_max_filesize);
            $curr_upload_status = "<font class=\"s4_color\">{$lang['step2AttachAllowSize']}: {$max_size}</font>";
        } else {
            $curr_upload_status = "<font color='red'>{$lang['step2AttachDisabled']}</font>";
            $msg .= "<span class='err'>{$lang['step2AttachDisabledTip']}</span><br>";
            $nextAccess = 0;
            $extend .= '{A}' . $lang['step2AttachDisabledTip'] . "\n";
        }
        $curr_php_version = PHP_VERSION;
        if ($curr_php_version < '4.1.0') {
            $curr_php_version = "{$curr_php_version} <font color='red'>{$lang['step2PHPVersionTooLowTip']}</font>";
            $nextAccess = 0;
            $extend .= '{B}' . $lang['step2PHPVersionTooLowTip'] . "\n";
        }