Vergleich global.php - 1.02 - 1.11

  Keine Änderungen   Hinzugefügt   Modifiziert   Entfernt
Zeile 8Zeile 8
 *
* $Id: global.php 900 2005-11-18 03:31:58Z chris $
*/

 *
* $Id: global.php 900 2005-11-18 03:31:58Z chris $
*/

 

if(strpos(strtolower($_SERVER['PHP_SELF']), "global.php") !== false)
{
die("Direct initialization of this file is not allowed.");
}

// This is a temporary patch put in place until 1.2 is released.
if((@ini_get("register_globals") || !@ini_get("gpc_order")) && (isset($_POST) || isset($_GET) || isset($_COOKIE)))
{
foreach(array_keys($_GET+$_POST+$_COOKIE) as $key)
{
unset($$key);
}
}


require "./inc/init.php";



require "./inc/init.php";


Zeile 23Zeile 37


pageheaders();



pageheaders();







if(is_dir("install") && !file_exists("install/lock"))
{
$mybb->trigger_generic_error("install_directory");

if(is_dir("install") && !file_exists("install/lock"))
{
$mybb->trigger_generic_error("install_directory");

Zeile 32Zeile 46

//
// Create this users session


//
// Create this users session

//
if(isset($nosession[$mybb->input['action']]))

//
if(isset($nosession[$mybb->input['action']]) || isset($mybb->input['thumbnail']))

{
define("NO_ONLINE", 1);
}
require "./inc/class_session.php";
$session = new session;
$session->init();

{
define("NO_ONLINE", 1);
}
require "./inc/class_session.php";
$session = new session;
$session->init();





$plugins->run_hooks("global_start");

//

$plugins->run_hooks("global_start");

//

Zeile 65Zeile 79
// Which thread mode is our user using?
if(!$mybb->input['mode'])
{

// Which thread mode is our user using?
if(!$mybb->input['mode'])
{

	if($mybb->user['threadmode'])
{
$mode = $mybb->user['threadmode'];
}
elseif($mybb->settings['threadusenetstyle'] == "yes")
{
$mode = "threaded";
}
else
{
$mode = "linear";
}

    if($mybb->user['threadmode'])
{
$mybb->input['mode'] = $mybb->user['threadmode'];
}
elseif($mybb->settings['threadusenetstyle'] == "yes")
{
$mybb->input['mode'] = "threaded";
}
else
{
$mybb->input['mode'] = "linear";
}

}

$loadstyle = "";

}

$loadstyle = "";

Zeile 195Zeile 209
	eval("\$welcomeblock = \"".$templates->get("header_welcomeblock_guest")."\";");
}
$unreadreports = "";

	eval("\$welcomeblock = \"".$templates->get("header_welcomeblock_guest")."\";");
}
$unreadreports = "";

if($mybb->usergroup['cancp'] == "yes" || $mybb->usergroup['issupermod'] == "yes" || $mcache[$mybb->user['uid']])

if($mybb->usergroup['cancp'] == "yes" || $mybb->usergroup['issupermod'] == "yes" || $mybb->usergroup['gid'] == 6)

{
$reported = $cache->read("reportedposts");
if($reported['unread'] > 0)

{
$reported = $cache->read("reportedposts");
if($reported['unread'] > 0)

Zeile 311Zeile 325
// Referrals system
if(!$mybb->user['uid'] && $mybb->settings['usereferrals'] == "yes" && intval($mybb->input['referrer']) > 0 && !$_COOKIE['mybb']['referrer'])
{

// Referrals system
if(!$mybb->user['uid'] && $mybb->settings['usereferrals'] == "yes" && intval($mybb->input['referrer']) > 0 && !$_COOKIE['mybb']['referrer'])
{

	$query = $db->query("SELECT * FROM ".TABLE_PREFIX."users WHERE uid='".$mybb->input['referrer']."'");

	$query = $db->query("SELECT * FROM ".TABLE_PREFIX."users WHERE uid='".intval($mybb->input['referrer'])."'");

	$referrer = $db->fetch_array($query);
if($referrer['uid'])
{

	$referrer = $db->fetch_array($query);
if($referrer['uid'])
{