Beispiel #1
0
function kleeja_run_hook($hookname)
{
    global $plugin;
    if (!$plugin) {
        include_once PATH . 'includes/classes/plugins.php';
        $plugin = new plugins();
    }
    return $plugin->run_hook($hookname);
}
Beispiel #2
0
#site close message if enabled
$login_page = '';
if ($config['siteclose'] == '1' && !user_can('enter_acp') && !defined('IN_LOGIN') && !defined('IN_ADMIN')) {
    #if download, images ?
    if (defined('IN_DOWNLOAD') && (ig('img') || ig('thmb') || ig('thmbf') || ig('imgf'))) {
        @$SQL->close();
        $fullname = "images/site_closed.jpg";
        $filesize = filesize($fullname);
        header("Content-length: {$filesize}");
        header("Content-type: image/jpg");
        readfile($fullname);
        exit;
    }
    #Send a 503 HTTP response code to prevent search bots from indexing the maintenace message
    header('HTTP/1.1 503 Service Temporarily Unavailable');
    kleeja_info($config['closemsg'], $lang['SITE_CLOSED']);
}
#exceed total size
if ($stat_sizes >= $config['total_size'] * 1048576 && !defined('IN_LOGIN') && !defined('IN_ADMIN')) {
    // Send a 503 HTTP response code to prevent search bots from indexing the maintenace message
    header('HTTP/1.1 503 Service Temporarily Unavailable');
    kleeja_info($lang['SIZES_EXCCEDED'], $lang['STOP_FOR_SIZE']);
}
#check for rows per page number
if (empty($perpage) || intval($perpage) == 0) {
    $perpage = 14;
}
#captcha file path
$captcha_file_path = $config['siteurl'] . 'captcha.php';
($hook = $plugin->run_hook('end_common')) ? eval($hook) : null;
//run hook