// session_start();
include 'TPGP_db.php';
// self post data
$Submit = $_POST['Submit'];
$StudentID = $_POST['sid'];
$EntryDate = $_POST['EntryDate'];
$SStepID = $_POST['SStepID'];
$SubValue = $_POST['SubValue'];
$WorkHours = $_POST['WorkHours'];
/* Let's strip some slashes in case the user entered
any escaped characters. */
$Submit = stripslashes($Submit);
$StudentID = stripslashes($StudentID);
$EntryDate = stripslashes($EntryDate);
$SStepID = stripslashes($SStepID);
$SubValue = stripslashes($SubValue);
$WorkHours = stripslashes($WorkHours);
// echo $PHP_SELF
// THIS IS WHERE THE SELF POST FORM GOES
// Define post fields into simple variables
if ($Submit == "Add StudentSubStep") {
$sql2 = "INSERT into ststeps (UserID,EntryDate,SStepID,SubValue, WorkHours) VALUES ('$EnrollmentID','$Evaluation','$EvalDate','$Assignment','$Extras','$Unit','$Lesson')";
mysql_query($sql2);
} else {
// $PHP_SELF as the form action will cause the script to post to itself
$StudentID = $_GET['ID'];
} // END ELSE IF
echo "";
echo "
';
$RURL = "TPGP_Update.php?ID=" .$StudentID;
print "Click here to return to the other weekly reports for this student!";
// THIS IS WHERE THE SELF POST FORM ENDS
// mysql_close($dbcon);
?>