You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

89 lines
3.1 KiB

<?php
/*
*
* @copyright (c) 2009 animegame.eu
* @license http://www.gnu.org/licenses/gpl-3.0.html GNU General Public Licence
*
*/
/*
* Hier muss echt mal aufgeräumt werden
* ne Menge altlasten hier
*/
// Immer den ganzen Pfad angeben, dann hat man es einfacher ^^
include_once ($_SERVER['DOCUMENT_ROOT'] . 'ag/include/config/db.inc.php');
include_once ($_SERVER['DOCUMENT_ROOT'] . 'ag/include/config/server.inc.php');
include_once ($_SERVER['DOCUMENT_ROOT'] . 'ag/include/config/settings.inc.php');
include_once ($_SERVER['DOCUMENT_ROOT'] . 'ag/include/speed_config.inc.php');
include_once ($_SERVER['DOCUMENT_ROOT'] . 'ag/include/online.inc.php');
include_once ($_SERVER['DOCUMENT_ROOT'] . 'ag/include/parse.inc.php');
include_once ($_SERVER['DOCUMENT_ROOT'] . 'ag/include/user.inc.php');
include_once ($_SERVER['DOCUMENT_ROOT'] . 'ag/include/usergroup.inc.php');
// Referer statistics (no use for this in the moment)
//$rs = strpos($_SERVER['HTTP_REFERER'],'//');
//if($rs !== FALSE){
// $rs += 2;
// $ls = strpos($_SERVER['HTTP_REFERER'],'/', $rs);
// if($ls !== FALSE){
// $referer = substr($_SERVER['HTTP_REFERER'],$rs, $ls-$rs);
// } else{
// $referer = substr($_SERVER['HTTP_REFERER'],$rs);
// }
//}
//
//mysql_query('Update referer set anzahl = anzahl + 1 where url = \''.$referer.'\' and datum = CURRENT_DATE');
//if(mysql_affected_rows() == 0){
// mysql_query('Insert into referer(url, anzahl, datum) values(\''.$referer.'\', 1, CURRENT_DATE)');
//}
$name = validateName($_COOKIE['name']);
$passwort = validateString($_COOKIE['passwort']);
$usergroups = array();
if(!checkCookiePassword($name, $passwort)){
$POLOE = 1;
$user_ida = array();
} else {
$user_ida = mysql_fetch_assoc(mysql_query("SELECT * FROM user WHERE nickname='$name' LIMIT 1"));
$usergroups = getUserGroups($name);
mysql_query('UPDATE user SET ip=\'' . $_SERVER['REMOTE_ADDR'] . '\', online_zeit=now() WHERE id='.$user_ida['id']);
if ($online_rekord_1_0['anzahl'] < $online_r) {
mysql_query('UPDATE online SET anzahl='.$online_r.', datum=now() WHERE id=1');
}
}
$banned_accs = mysql_num_rows(mysql_query("SELECT id FROM user WHERE ip!='' AND ip='$user_ida[ip]' AND id!='$user_ida[id]' LIMIT 2"));
$clan_nachricht = mysql_fetch_array(mysql_query("SELECT i.id FROM clan_k_list i LEFT JOIN clan c ON(c.id=i.an) WHERE i.anzeige='1' AND (c.leader='$user_ida[id]' OR c.co_leader='$user_ida[id]') AND i.an='$user_ida[clan]' LIMIT 1"));
if ($user_ida['id'] != null) {
$as = 'profil';
}
$pic_g31 = 75; ///////////Bild Groesse
if ($clan_nachricht['id']) {
print " <script language='JavaScript'>
<!--
alert('Sie wurden zum Clankampf Herausgefordert.');
//-->
</script>";
mysql_query("UPDATE clan_k_list SET anzeige='0' WHERE id='$clan_nachricht[id]' LIMIT 1");
}
/*if($user_ida[post]) {
$nachricht = mysql_fetch_assoc(mysql_query("SELECT count(id) as anzahl FROM nachricht WHERE aktiv='1' AND besitzer='$user_ida[id]' LIMIT 1"));
if($nachricht['anzahl'] > 0) {
print ' <script language="JavaScript"">
<!--
alert("Sie haben '.$nachricht['anzahl'].' neue Nachrichten erhalten");
//-->
</script>';
mysql_query("UPDATE nachricht SET aktiv='0' WHERE besitzer='$user_ida[id]'");
}
}
*/
?>