/** * Sends the appropriate HTTP headers for the page that is being displayed * * @param boolean If true, send HTTP 200 * @param boolean If true, send no-cache headers */ function exec_headers($headers = true, $nocache = true) { global $vbulletin; $contenttype = $vbulletin->contenttype ? $vbulletin->contenttype : 'text/html'; $sendcontent = true; if ($vbulletin->options['addheaders'] AND !$vbulletin->noheader AND $headers) { // default headers if (SAPI_NAME == 'cgi' OR SAPI_NAME == 'cgi-fcgi') { header('Status: 200 OK'); } else { header('HTTP/1.1 200 OK'); } @header('Content-Type: ' . $contenttype . iif($vbulletin->userinfo['lang_charset'] != '', '; charset=' . $vbulletin->userinfo['lang_charset'])); $sendcontent = false; } if ($vbulletin->options['nocacheheaders'] AND !$vbulletin->noheader AND $nocache) { // no caching exec_nocache_headers($sendcontent); } else if (!$vbulletin->noheader) { @header("Cache-Control: private"); @header("Pragma: private"); if ($sendcontent) { $charset = $vbulletin->userinfo['lang_charset'] ? $vbulletin->userinfo['lang_charset'] : vB_Template_Runtime::fetchStyleVar('charset'); @header('Content-Type: ' . $contenttype . '; charset=' . $charset); } } if ($vbulletin->options['forceie8']) { //Disable any IE emulate option @header('X-UA-Compatible: IE=8'); } }
{ $specialtemplates = array(); } $specialtemplates[] = 'pluginlistadmin'; // ###################### Start functions ####################### chdir('./../'); define('CWD', (($getcwd = getcwd()) ? $getcwd : '.')); require_once(CWD . '/includes/init.php'); require_once(DIR . '/includes/adminfunctions.php'); require_once(DIR . '/includes/modfunctions.php'); require_once(DIR . '/includes/functions_calendar.php'); // ###################### Start headers ####################### exec_nocache_headers(); if ($vbulletin->userinfo['cssprefs'] != '') { $vbulletin->options['cpstylefolder'] = $vbulletin->userinfo['cssprefs']; } // ###################### Get date / time info ####################### // override date/time settings if specified fetch_options_overrides($vbulletin->userinfo); fetch_time_data(); // ############################################ LANGUAGE STUFF #################################### // initialize $vbphrase and set language constants $vbphrase = init_language(); $_tmp = NULL;
/** * Sends the appropriate HTTP headers for the page that is being displayed * * @param boolean If true, send HTTP 200 * @param boolean If true, send no-cache headers */ function exec_headers($headers = true, $nocache = true) { global $vbulletin; $sendcontent = true; if ($vbulletin->options['addheaders'] and !$vbulletin->noheader and $headers) { // default headers if (SAPI_NAME == 'cgi' or SAPI_NAME == 'cgi-fcgi') { header('Status: 200 OK'); } else { header('HTTP/1.1 200 OK'); } @header('Content-Type: text/html' . iif($vbulletin->userinfo['lang_charset'] != '', '; charset=' . $vbulletin->userinfo['lang_charset'])); $sendcontent = false; } if ($vbulletin->options['nocacheheaders'] and !$vbulletin->noheader and $nocache) { // no caching exec_nocache_headers($sendcontent); } else { if (!$vbulletin->noheader) { @header("Cache-Control: private"); @header("Pragma: private"); if ($sendcontent) { @header('Content-Type: text/html' . iif($vbulletin->userinfo['lang_charset'] != '', '; charset=' . $vbulletin->userinfo['lang_charset'])); } } } // IE8 emulate IE7 mode if ($vbulletin->options['ie8render7']) { @header('X-UA-Compatible: IE=7'); } }