Beispiel #1
0
<?php

require_once "../force-https.php";
include_once "dbo.php";
ini_set('session.use_trans_sid', false);
ini_set('session.save_handler', 'files');
ini_set('session.save_path', $GLOBALS['TMP_DIR']);
ini_set('arg_separator.output', '&amp;');
session_start();
require_once '../utils.php';
// Set $_GET[...] variables to their $_POST equivalents
set_get_post('file');
set_get_post('search');
set_get_post('category');
set_get_post('subcategory');
set_get_post('commentsearch');
require_once '../header.php';
require_once 'utils.php';
require_once "sidebar.php";
process_params();
/*
 * Process the URL parameters in a natural order
 * Note:  Most of these perform a function and return, but some, such as
 * file and rate perform a function and continue to remain consistent with
 * old functionality.  TODO:  Determine if the continue's are needed.
 */
function process_params()
{
    $post_funcs = explode(',', POST_FUNCS);
    foreach ($post_funcs as $func) {
        if (!GET_EMPTY($func)) {
Beispiel #2
0
function login()
{
    if (SESSION_EMPTY() && GET('action') == 'login') {
        if (password_match(POST('password'), POST('login'))) {
            $_SESSION["remote_user"] = POST('login');
            $_GET["action"] = POST('oldaction');
            set_get_post('category');
            set_get_post('subcategory');
            return true;
        }
    }
    return false;
}