Пример #1
0
    phpinfo();
} else {
    // The installer
    html_header();
    html_logo();
    if (file_exists($DFLT['cfg_f'])) {
        html_installer_locked();
    } elseif (count($_POST)) {
        test_fs();
        test_sql_connection();
        test_admin_login();
        write_config_file();
        if ($errors == '') {
            create_tables();
        }
        if ($errors != '') {
            html_input_config($errors);
        } else {
            //lock_install();
            html_install_success($notes);
        }
    } else {
        test_fs();
        if ($errors != '') {
            html_prereq_errors($errors);
        } else {
            html_input_config();
        }
    }
    html_footer();
}
Пример #2
0
function start_update()
{
    // The updater
    html_header("Coppermine - Upgrade");
    html_logo();
    test_fs();
    if ($errors != '') {
        html_prereq_errors($errors);
    } else {
        test_sql_connection();
        if ($errors == '') {
            update_tables();
            update_system_thumbs();
        } else {
            html_error($errors);
        }
        if ($errors == '') {
            html_install_success($notes);
            session_destroy();
        } else {
            html_error($errors);
        }
    }
    html_footer();
}
Пример #3
0
function start_update()
{
    global $errors, $notes, $lang_update_php, $LINEBREAK;
    global $update_icon, $ok_icon, $already_done_icon, $error_icon, $file_system_icon;
    // The updater
    //html_header($lang_update_php['title']);
    test_sql_connection();
    if (function_exists('cpg_fetch_icon')) {
        $update_icon = cpg_fetch_icon('update_database', 2);
        $ok_icon = cpg_fetch_icon('ok', 2);
        $already_done_icon = cpg_fetch_icon('info', 2);
        $error_icon = cpg_fetch_icon('stop', 2);
        $file_system_icon = cpg_fetch_icon('hdd', 2);
    } else {
        $update_icon = '';
        $ok_icon = '';
        $already_done_icon = '';
        $error_icon = '';
        $file_system_icon = '';
    }
    if ($errors == '') {
        echo '        <table border="0" cellspacing="0" cellpadding="0" class="maintable">' . $LINEBREAK;
        update_tables();
        update_files();
        echo '        </table>' . $LINEBREAK;
    } else {
        html_error($errors);
    }
    if ($errors == '') {
        html_install_success($notes);
        session_destroy();
    } else {
        html_error($errors);
    }
    //html_footer();
}