$login_check = mysqli_query($con,"SELECT `id` FROM `user` WHERE `username`='$username' AND `password`='".sha1($front_salt.$password.$back_salt)."'") or die (mysqli_error($con));
$activated_check = mysqli_query($con,"SELECT `activated` FROM `user` WHERE `username`='$username' AND `password`='".sha1($front_salt.$password.$back_salt)."'") or die (mysqli_error($con));
$user = mysqli_query($con,"SELECT `id`,`privileges`,`activated` FROM `user` WHERE `username`='$username' AND `password`='".sha1($front_salt.$password.$back_salt)."'") or die (mysqli_error($con));
Neni mi jasne, proc na user check, activated a privilegia pouzivas 100.000 a 1 sql dotazu, kdyz staci 1.