Пример #1
0
<?php

if (!defined('is_running')) {
    define('is_running', true);
    define('gpdebug', false);
    define('gp_cookie_cmd', false);
    //define('gp_dev_combine',false); //prevents cache and 304 header when set to true
    require_once 'common.php';
    \gp\tool::EntryPoint(1, 'image.php', false);
    new gp_resized();
}
class gp_resized
{
    public $img;
    public $height;
    public $width;
    public static $index = false;
    private static $index_checksum = false;
    private static $last_index = '9';
    /**
     * Check the path of the img, return full path of image if the requested image is found
     *
     */
    function __construct()
    {
        global $dataDir;
        if (!isset($_GET['w']) || !isset($_GET['h']) || !isset($_GET['img'])) {
            self::Send404();
            //dies
        }
        $img = $_GET['img'];
Пример #2
0
<?php

define('gp_start_time', microtime(true));
defined('is_running') or define('is_running', true);
require_once 'common.php';
\gp\tool::EntryPoint(0);
/*
 *	Flow Control
 */
if (!empty($GLOBALS['config']['updating_message'])) {
    die($GLOBALS['config']['updating_message']);
}
$title = \gp\tool::WhichPage();
$type = \gp\tool::SpecialOrAdmin($title);
switch ($type) {
    case 'special':
        $page = new \gp\special\Page($title, $type);
        break;
    case 'admin':
        if (\gp\tool::LoggedIn()) {
            $page = new \gp\admin\Page($title, $type);
        } else {
            $page = new \gp\admin\Login($title, $type);
        }
        break;
    default:
        if (\gp\tool::LoggedIn()) {
            $page = new \gp\Page\Edit($title, $type);
        } else {
            $page = new \gp\Page($title, $type);
        }
Пример #3
0
<?php

define('is_running', true);
//define('gpdebug',true);
require_once '../common.php';
\gp\tool::EntryPoint(2, 'update.php');
/* check permissions */
if (!\gp\tool::LoggedIn()) {
    die('You must be logged in to access this area.');
}
if (!isset($gpAdmin['granted']) || $gpAdmin['granted'] !== 'all') {
    die('Sorry, you do not have sufficient privileges to access this area.');
}
\gp\tool::GetLangFile();
$page = new \gp\admin\Update();
\gp\tool\Output::HeadContent();
includeFile('install/template.php');