PrgStart(); echo('
'); $Expansion = array(0 => 'Klasický', 1 => 'The Burning Crusade', 2 => 'Wrath of the Litch King'); if(array_key_exists('aa', $_POST)) if(array_key_exists('ab', $_POST)) if(array_key_exists('vyber', $_POST)) { $account= @$_POST['aa']; $heslo= @$_POST['ab']; $vyber = @$_POST['vyber']; if($account != '' || $heslo != '') { $db->select_db($Config['Mangos']['DatabaseRealmd']); $user2 = strtoupper($account); $pass = strtoupper($heslo); $i = SHA1($user2.':'.$pass); $data = $db->query('SELECT id FROM `account` WHERE username="'.$account.'" AND sha_pass_hash="'.$i.'" LIMIT 0,1'); $id = $data->fetch_assoc(); if($id['id'] == '') { die('Špatně zadané údaje účtu.'); } switch($vyber) { case 'wotlk': $nastaveni = 2; break; case 'tbc': $nastaveni = 1; break; case 'wow': $nastaveni = 0; break; } $querko = $db->query('UPDATE `account` SET `expansion` = '.$nastaveni.' WHERE `username` = "'.$account.'"'); if($nastaveni == 1) { echo('