"; if (TO_DO=="login") { $login=$_POST['login']; $query=mysqli_query($db, "SELECT `password` FROM `player` WHERE `alias` = '$login' AND `password` IS NOT NULL LIMIT 0 , 30"); $data=mysqli_fetch_array($query); if ($data!==NULL && $data!==False && password_verify($_POST['password'], $data['password'])) { $_SESSION['login']=$login; } else { $ERROR.="Login nicht erfolgreich!
"; } } if ($page=="logout") { $_SESSION['login']=""; $page=""; } if (isset($_SESSION['login'])) define ("LOGIN",$_SESSION['login']); else define ("LOGIN",""); if (LOGIN!="") { $BODY.='
'.add_icon('user')."  ".LOGIN."    "; $BODY.=''.add_icon("new_game").'Neues Spiel    '; $BODY.=''.add_icon("arrow_out").'Rangliste Aktualisieren    '; $BODY.="
"; } $BODY.="

"; //include the requestet page if ($page=="login") include ("login.php"); elseif ($page=="rank" ) include ("rank.php" ); elseif ($page=="games" ) include ("games.php" ); elseif ($page=="edit_game" ) include ("edit_game.php" ); elseif ($page=="poker_pott") include("poker_pott.php"); else include ("main.php"); //include the Template include ("template.php"); //End of Script mysqli_close($db); ?>