here."; // END IF greater than one row found inthe class list. } else { // $PHP_SELF as the form action will cause the script to post to itself $EnrollmentID = $_GET['ID']; } // END ELSE IF // ************************************************************************* $theSQL = "SELECT enrollment.EnrollmentID, classes.ClassName, enrollment.ClassID, enrollment.StudentID, enrollment.FinalGrade, enrollment.CreditsEarned, enrollment.StartDate, enrollment.EndDate, enrollment.CreditsPotential, enrollment.CreditsActual, enrollment.Status, enrollment.class, enrollment.subject FROM enrollment LEFT JOIN classes ON enrollment.ClassID = classes.ClassId WHERE enrollment.EnrollmentID ='$EnrollmentID'"; $sql444 = mysql_query($theSQL); // echo $theSQL; $record_found = mysql_num_rows($sql444); // echo $record_found; if($record_found > 0){ while($row = mysql_fetch_array($sql444)){ foreach( $row AS $key => $val ){ $$key = stripslashes( $val ); } // echo $row; // echo $key; // echo $$key; $StudentId = $StudentID; $theClassName = $ClassName; // echo $UserID; // echo $StudentId; } } // ************************************************************************ $theStudentID = $StudentId; $sql = mysql_query("SELECT * FROM users WHERE userid='$theStudentID'"); $record_found = mysql_num_rows($sql); if($record_found > 0){ while($row = mysql_fetch_array($sql)){ foreach( $row AS $key => $val ){ $$key = stripslashes( $val ); } // END FOR echo "View Student Information

 

"; $query="SELECT * FROM reports WHERE (StudentID ='$theStudentID' AND CreditsTOTAL > 0) ORDER BY EndDate DESC LIMIT 1"; // print "$query"; $result=mysql_query($query); $num=mysql_numrows($result); $i=0; while ($i < $num) { $row99=mysql_fetch_array($result); $CC = $row99["CreditsTPGP"]; // print "$CC"; $CO = $row99["CreditsOTHER"]; // print "$CO"; $CT = $row99["CreditsTOTAL"]; $CG = $row99["CreditsGOAL"]; // CODE echo ''; $i++; } // END WHILE INNER LOOP RECORDSET - last report } // END WHILE echo '
STUDENT INFORMATION :
Name : $first_name $last_name
Login : $username
Email : $email_address
Credits Completed (TPGP) : '.$CC.'
Credits Completed (OTHER) : '.$CO.'
Credits Total : '.$CT.'
Credits Goal : '.$CG.'
'; } // END IF else { echo "Session Variables Timed Out - Please login again."; } // ****************************************************************** $RURL = "TPGP_UpdateEnrollment.php?ID=" .$StudentID; echo ""; // %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% echo '
CLASS ["'.$theClassName.'"] - ( Click here to return to the Class page for this student)

'; // %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% $sql="SELECT enrollment.StudentID, endetails.endetailID, endetails.enrollmentID, endetails.evaluation, endetails.evaldate, endetails.assignment, endetails.extras, endetails.unit, endetails.lesson FROM endetails INNER JOIN enrollment ON endetails.enrollmentID = enrollment.EnrollmentID WHERE endetails.enrollmentID=" .$EnrollmentID. " ORDER BY endetails.endetailID"; $result = mysql_query($sql); $nrows = mysql_num_rows($result); if($nrows != 0) { print ""; print ""; print ""; print ""; print ""; print ""; print ""; print ""; print ""; print ">"; for($j=0;$j<$nrows;$j++) { $row = mysql_fetch_array($result); $StudentID = $row["StudentID"]; $EditURL = "TPGP_EditEnroll.php?ID=" . $row['endetailID']; $DeleteURL = "TPGP_DeleteEnroll.php?ID=" . $row['endetailID']; $UnitsURL = "TPGP_EditEnroll.php?ID=" . $row['endetailID']; print ""; } else{ print "
FUNCTION"; print "Unit "; print "Lesson"; print "Evaluation"; print "Evaluation Date"; print "Assignment"; print "Extras
EDIT"; print " DELETE"; print "" . $row["unit"]; print "" . $row["lesson"]; // ******************************************** $theval=$row["evaluation"]; $theval=(double)$theval; // ******************************************** if ($theval >= 70.0){ print "" . $theval . "" . $theval . ""; } print "" . $row["evaldate"]; print "" . $row["assignment"]; print "" . $row["extras"]; print "\n"; } print "


\n"; // $RURL = "TPGP_UpdateEnrollment.php?ID=" .$StudentID; print "Click here to return to the other classes that this student is enrolled in!\n"; } $list_comp = $row["enrollmentID"]; // $RURL = "TPGP_UpdateEnrollment.php?ID=" .$StudentID; echo '
Add New Unit / Lesson

UNIT : NEW CLASS ['.$theClassName.']

Update Units / Lessons
Unit
Lesson
Evaluation
Eval Date (YYYY-MM-DD)
Assignment
Extras

    

'; $RURL = "TPGP_UpdateEnrollment.php?ID=" .$StudentID; print "Click here to return to the other classes that this student is enrolled in!"; // THIS IS WHERE THE SELF POST FORM ENDS // mysql_close($dbcon); ?>