Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- include 'includes/config.php';
- if(isset($_POST['username']) && isset($_POST['password'])){
- $username = sec($_POST['username']);
- $password = sec(strtoupper(hash("whirlpool",$_POST['password'])));
- $check = get_row("SELECT id FROM players WHERE Name='$username' && Password='$password'");
- if(isset($check['id'])){
- $banned = get_row("SELECT * FROM banuri WHERE Nume='$username'");
- if(isset($banned['id'])){
- if($banned['BanaP'] == 0){
- $err = 'Eşti banat permanent.';
- }else{
- $err = 'Eşti banat până la data de '.$banned['BanzP'].'.'.$banned['BanlP'].'.'.$banned['BanaP'].' '.$banned['BanoP'].':'.$banned['BanmP'];
- }
- }else{
- $_SESSION['username'] = $_POST['username'];
- $_SESSION['password'] = $password;
- mysql_query("UPDATE players SET rpgon=2 WHERE Name='$username'");
- header('location: index.php');
- }
- }else{
- $err = 'Numele de utilizator ori parola incorecte.';
- }
- }
- include 'includes/header.php';
- ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement