Ckizen's Posts
Nairaland Forum › Ckizen's Profile › Ckizen's Posts
1 (of 1 pages)
This is a great info. Pls read and share. |
THIS IS IS SOURCE CODE TO CHECK IT. <?php include("Connection/connection.php" ;session_start(); $pin =$_POST['tCpin']; $session =$_POST['session']; $term = $_POST['term']; $class = $_POST['class']; $sql="SELECT * FROM card_pin WHERE PIN ='$pin' and STATUS ='UNUSED' "; $result=mysql_query($sql); // Mysql_num_row is counting table row $count=mysql_num_rows($result); // If result matched $myusername and $mypassword, table row must be 1 row $_SESSION['pin'] = $pin; $_SESSION['session'] = $session; $_SESSION['term'] = $term; $_SESSION['class'] = $class; if($count==1){ header("location:Students_in_a_class.php" ;} else { header("location:No_student_found.php" ;} ?> |
ckizen:. Pls can someone help me out with the right code?? |
Pls I have a Result Checker application developed with PHP, but my problem now is how to code the pin so that a student can use the same PIN for the entire session (first, second and third term) . With a maximium of 10 usage each term. Thanks |
1 (of 1 pages)
;