Smart Salesperson Appointment Management System (SSAMS)
Flexible way to process new employees appointment or recruitment at Ines-Ruhengeri Login to Proceed

© Copyright Ines-Ruhengeri
CONTACT US:
Musanze, Street, NM 155
Po Box: 155 Ruhengeri
Registration office: +250 736 444 413
Mobile: +250 788 903 030 / +250 788 903 032

connect_error) { die("Connection failed: " . $conn->connect_error); } if(isset($_POST['logbtn'])) { $user_email=$_POST['uname']; // $func=$_POST['rol']; $user_pass=sha1($_POST ['pswd']); $tod=date('Y-m-d'); $stmt=$conn->prepare("select firstName,lastName,userName,eMail,passWord from users WHERE userName=? AND passWord=? LIMIT 1") or die("Fail to fetch data").Mysqli_error($conn); $stmt2 = $conn -> prepare('SELECT COUNT(AppId) as appilz from apeals WHERE dat=?'); $stmt2->bind_param("s", $tod); $stmt2 -> execute(); $stmt2 -> store_result(); //$appz=$stmt2 -> num_rows; $stmt2 -> bind_result($appilz); $stmt2->fetch(); $_SESSION['appealz']=$appilz; $stmt->bind_param("ss", $user_email,$user_pass); $stmt->execute(); $stmt->store_result(); $n=$stmt-> num_rows; $stmt->bind_result($firstName, $lastName, $userName, $eMail, $passWord); $stmt->fetch(); $_SESSION['fn']=$firstName; $_SESSION['ln']=$lastName; if($n == 1) { $_SESSION['user']=$user_email; echo ""; } else { echo ""; } }