Ejemplo n.º 1
0
            $isValid = true;
        }
    } else {
        $_SESSION["ATTEMPT"] += 1;
        $isValid = false;
    }
    if (!$isValid) {
        if ($_SESSION["ATTEMPT"] >= 10) {
            $post->ipBlackList();
            die("Max Attempt");
        } else {
            header('WWW-Authenticate: Basic realm="sedotpress"');
            header('HTTP/1.0 401 Unauthorized');
            die("Not authorized");
        }
    }
    die(include 'admin.php');
} else {
    $_SINGLE_POST = true;
    $pointer = $post->search(2, $getRequest[0]);
    $pointer = key($pointer);
    if (!$pointer || $pointer == '' || is_null($pointer)) {
        header('HTTP/1.0 404 Not Found');
        $_SINGLE_POST = false;
        $_PAGE_404 = true;
        goto bypass;
    }
    $entry = $post->formatPost($pointer);
    bypass:
}
require 'sp_theme/' . THEME . '/template.php';