Submissions.php: replace frm with form
parent
6257818b86
commit
593ac0219a
|
@ -66,7 +66,7 @@ if ($_SESSION['user_type'] != "Lecturer" && $_SESSION['user_type'] != "Admin") {
|
||||||
|
|
||||||
?>
|
?>
|
||||||
<form method="post" action="Script.php" id="create_account_form">
|
<form method="post" action="Script.php" id="create_account_form">
|
||||||
<input type="hidden" name="frm_createlecturrer" value="true" required="" />
|
<input type="hidden" name="form_createlecturrer" value="true" required="" />
|
||||||
Full name
|
Full name
|
||||||
<input type="text" name="fullname" placeholder="Full Name" class="form-control" required=""> <br>
|
<input type="text" name="fullname" placeholder="Full Name" class="form-control" required=""> <br>
|
||||||
Email
|
Email
|
||||||
|
|
12
Courses.php
12
Courses.php
|
@ -110,7 +110,7 @@ include 'Header.php';
|
||||||
$_SESSION['Type'] = $row1['Type'];
|
$_SESSION['Type'] = $row1['Type'];
|
||||||
}
|
}
|
||||||
|
|
||||||
if(isset($_POST['frm_uploadlab'])){
|
if(isset($_POST['form_uploadlab'])){
|
||||||
$deadlinedate = trim(mysqli_real_escape_string($con, $_POST["deadlinedate"])); // remove spaces
|
$deadlinedate = trim(mysqli_real_escape_string($con, $_POST["deadlinedate"])); // remove spaces
|
||||||
$deadlinetime = trim(mysqli_real_escape_string($con, $_POST["deadlinetime"])); // remove spaces
|
$deadlinetime = trim(mysqli_real_escape_string($con, $_POST["deadlinetime"])); // remove spaces
|
||||||
$instructions = mysqli_real_escape_string($con, $_POST["instructions"]);
|
$instructions = mysqli_real_escape_string($con, $_POST["instructions"]);
|
||||||
|
@ -130,7 +130,7 @@ include 'Header.php';
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if(isset($_POST['frm_deletelab'])) {
|
if(isset($_POST['form_deletelab'])) {
|
||||||
$sql = "DELETE FROM lab_reports_table WHERE Lab_Report_ID='$getid'";
|
$sql = "DELETE FROM lab_reports_table WHERE Lab_Report_ID='$getid'";
|
||||||
if ($con->query($sql) === TRUE) {
|
if ($con->query($sql) === TRUE) {
|
||||||
$_SESSION["info_Updated"]="Assignment deleted successfully.";
|
$_SESSION["info_Updated"]="Assignment deleted successfully.";
|
||||||
|
@ -152,7 +152,7 @@ include 'Header.php';
|
||||||
echo " <h3><a href='Courses.php?course=".$url."'>Editing assignment information</a></h3>";
|
echo " <h3><a href='Courses.php?course=".$url."'>Editing assignment information</a></h3>";
|
||||||
?>
|
?>
|
||||||
<form method='post' enctype='multipart/form-data' action=''>
|
<form method='post' enctype='multipart/form-data' action=''>
|
||||||
<input type='hidden' name='frm_uploadlab' value='true' required=''/>
|
<input type='hidden' name='form_uploadlab' value='true' required=''/>
|
||||||
<input type='hidden' name='course_id' value='<?php echo "$id" ?>' required=''/>
|
<input type='hidden' name='course_id' value='<?php echo "$id" ?>' required=''/>
|
||||||
<input type='hidden' name='url' value='<?php echo ".$course_url." ?>' required=''/>
|
<input type='hidden' name='url' value='<?php echo ".$course_url." ?>' required=''/>
|
||||||
|
|
||||||
|
@ -195,7 +195,7 @@ include 'Header.php';
|
||||||
</form><br><br><br><br>
|
</form><br><br><br><br>
|
||||||
|
|
||||||
<form method='post' action=''>
|
<form method='post' action=''>
|
||||||
<input type='hidden' name='frm_deletelab' value='true' required=''/>
|
<input type='hidden' name='form_deletelab' value='true' required=''/>
|
||||||
<input type='submit' class='btn btn-danger' value='Delete assignment'><br>
|
<input type='submit' class='btn btn-danger' value='Delete assignment'><br>
|
||||||
</form>
|
</form>
|
||||||
|
|
||||||
|
@ -217,7 +217,7 @@ include 'Header.php';
|
||||||
<?php
|
<?php
|
||||||
$_SESSION['url']=$url;
|
$_SESSION['url']=$url;
|
||||||
?>
|
?>
|
||||||
<input type='hidden' name='frm_uploadlab' value='true' required=''/>
|
<input type='hidden' name='form_uploadlab' value='true' required=''/>
|
||||||
<input type='hidden' name='course_id' value='<?php echo "$id" ?>' required=''/>
|
<input type='hidden' name='course_id' value='<?php echo "$id" ?>' required=''/>
|
||||||
<input type='hidden' name='url' value='<?php echo ".$course_url." ?>' required=''/>
|
<input type='hidden' name='url' value='<?php echo ".$course_url." ?>' required=''/>
|
||||||
|
|
||||||
|
@ -470,7 +470,7 @@ WHERE Lecturer_User_ID=$lecturer_id and course_students_table.Status='Pending'"
|
||||||
<b>Create a new course</b>
|
<b>Create a new course</b>
|
||||||
|
|
||||||
<form method="post" action="Script.php">
|
<form method="post" action="Script.php">
|
||||||
<input type="hidden" name="frm_createCourse" value="true" required=""/>
|
<input type="hidden" name="form_createCourse" value="true" required=""/>
|
||||||
<input type="hidden" name="l" value="l" required=""/>
|
<input type="hidden" name="l" value="l" required=""/>
|
||||||
Course name
|
Course name
|
||||||
<input type="text" name="name" placeholder="Course Name" class="form-control" required="">
|
<input type="text" name="name" placeholder="Course Name" class="form-control" required="">
|
||||||
|
|
14
Script.php
14
Script.php
|
@ -126,7 +126,7 @@ if (!empty($_POST["form_signup"])) {
|
||||||
|
|
||||||
// ################################ LOGIN #####################################
|
// ################################ LOGIN #####################################
|
||||||
|
|
||||||
if (!empty($_POST["frm_login"])) {
|
if (!empty($_POST["form_login"])) {
|
||||||
|
|
||||||
$user = mysqli_real_escape_string($con, $_POST["user"]); // user could be a 12-digit student number or an email address
|
$user = mysqli_real_escape_string($con, $_POST["user"]); // user could be a 12-digit student number or an email address
|
||||||
$is_student_number = 0;
|
$is_student_number = 0;
|
||||||
|
@ -187,7 +187,7 @@ if (!empty($_POST["frm_login"])) {
|
||||||
|
|
||||||
// ################################ Recover Password #####################################
|
// ################################ Recover Password #####################################
|
||||||
|
|
||||||
if (!empty($_POST["frm_recover_password"])) {
|
if (!empty($_POST["form_recover_password"])) {
|
||||||
|
|
||||||
$student_id = mysqli_real_escape_string($con, $_POST["sno"]);
|
$student_id = mysqli_real_escape_string($con, $_POST["sno"]);
|
||||||
$email = mysqli_real_escape_string($con, $_POST["email"]);
|
$email = mysqli_real_escape_string($con, $_POST["email"]);
|
||||||
|
@ -220,7 +220,7 @@ if (!empty($_POST["frm_recover_password"])) {
|
||||||
|
|
||||||
// ################################ RESET Password #####################################
|
// ################################ RESET Password #####################################
|
||||||
|
|
||||||
if (!empty($_POST["frm_reset_password"])) {
|
if (!empty($_POST["form_reset_password"])) {
|
||||||
$password = mysqli_real_escape_string($con, $_POST["password"]);
|
$password = mysqli_real_escape_string($con, $_POST["password"]);
|
||||||
$token = mysqli_real_escape_string($con, $_POST["token"]);
|
$token = mysqli_real_escape_string($con, $_POST["token"]);
|
||||||
$email = mysqli_real_escape_string($con, $_POST["email"]);
|
$email = mysqli_real_escape_string($con, $_POST["email"]);
|
||||||
|
@ -264,7 +264,7 @@ if (!empty($_POST["frm_reset_password"])) {
|
||||||
}
|
}
|
||||||
|
|
||||||
// ############################### CREATE Lecturer/TA USER ##################################
|
// ############################### CREATE Lecturer/TA USER ##################################
|
||||||
if (!empty($_POST["frm_createlecturrer"])) {
|
if (!empty($_POST["form_createlecturrer"])) {
|
||||||
$email = mysqli_real_escape_string($con, $_POST["email"]);
|
$email = mysqli_real_escape_string($con, $_POST["email"]);
|
||||||
$fullname = mysqli_real_escape_string($con, $_POST["fullname"]);
|
$fullname = mysqli_real_escape_string($con, $_POST["fullname"]);
|
||||||
$type = mysqli_real_escape_string($con, $_POST["type"]);
|
$type = mysqli_real_escape_string($con, $_POST["type"]);
|
||||||
|
@ -340,7 +340,7 @@ function mkdirs($path)
|
||||||
}
|
}
|
||||||
|
|
||||||
// ############################### #Post Assignment ##################################
|
// ############################### #Post Assignment ##################################
|
||||||
if (!empty($_POST["frm_uploadlab"])) {
|
if (!empty($_POST["form_uploadlab"])) {
|
||||||
|
|
||||||
$course_id = mysqli_real_escape_string($con, $_POST["course_id"]);
|
$course_id = mysqli_real_escape_string($con, $_POST["course_id"]);
|
||||||
$deadlinedate = $_POST["deadlinedate"];
|
$deadlinedate = $_POST["deadlinedate"];
|
||||||
|
@ -452,7 +452,7 @@ function checksize($file)
|
||||||
}
|
}
|
||||||
|
|
||||||
// ############################### Submit Assignment ##################################
|
// ############################### Submit Assignment ##################################
|
||||||
if (!empty($_POST["frm_submitlab"])) {
|
if (!empty($_POST["form_submitlab"])) {
|
||||||
|
|
||||||
$lab_id = mysqli_real_escape_string($con, $_POST["lab_id"]);
|
$lab_id = mysqli_real_escape_string($con, $_POST["lab_id"]);
|
||||||
$student_id = $_POST["student_id"];
|
$student_id = $_POST["student_id"];
|
||||||
|
@ -999,7 +999,7 @@ if (!empty($_GET["action"])) {
|
||||||
}
|
}
|
||||||
|
|
||||||
// ############################### CREATE STUDENT USER ##################################
|
// ############################### CREATE STUDENT USER ##################################
|
||||||
if (!empty($_POST["frm_createCourse"])) {
|
if (!empty($_POST["form_createCourse"])) {
|
||||||
$name = mysqli_real_escape_string($con, $_POST["name"]);
|
$name = mysqli_real_escape_string($con, $_POST["name"]);
|
||||||
$academic = mysqli_real_escape_string($con, $_POST["academic"]);
|
$academic = mysqli_real_escape_string($con, $_POST["academic"]);
|
||||||
$lecturer = mysqli_real_escape_string($con, $_POST["lecturer"]);
|
$lecturer = mysqli_real_escape_string($con, $_POST["lecturer"]);
|
||||||
|
|
|
@ -98,7 +98,7 @@ include 'Header.php';
|
||||||
|
|
||||||
|
|
||||||
<form method='post' enctype='multipart/form-data' action='Script.php'>
|
<form method='post' enctype='multipart/form-data' action='Script.php'>
|
||||||
<input type='hidden' name='frm_submitlab' value='true' required=''/>
|
<input type='hidden' name='form_submitlab' value='true' required=''/>
|
||||||
<input type='hidden' name='lab_id' value='<?php echo $id; ?>' required=''/>
|
<input type='hidden' name='lab_id' value='<?php echo $id; ?>' required=''/>
|
||||||
<input type='hidden' name='student_id' value='<?php echo $student_id; ?>' required=''/>
|
<input type='hidden' name='student_id' value='<?php echo $student_id; ?>' required=''/>
|
||||||
<input type='hidden' name='group_id' value='<?php echo $Group_ID; ?>' required=''/>
|
<input type='hidden' name='group_id' value='<?php echo $Group_ID; ?>' required=''/>
|
||||||
|
|
|
@ -26,9 +26,9 @@ if (isset($_SESSION["user_fullname"])) {
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="col-md-5">
|
<div class="col-md-5">
|
||||||
<form method="post" action="Script.php" name="frm_login">
|
<form method="post" action="Script.php" name="form_login">
|
||||||
<legend>Sign in</legend>
|
<legend>Sign in</legend>
|
||||||
<input type="hidden" name="frm_login" value="true"/>
|
<input type="hidden" name="form_login" value="true"/>
|
||||||
<label for="user_name" class="form-label">Account name</label>
|
<label for="user_name" class="form-label">Account name</label>
|
||||||
<input type="text" name="user" placeholder="Student Number / Email address" class="form-control" required="required" id="user_name" />
|
<input type="text" name="user" placeholder="Student Number / Email address" class="form-control" required="required" id="user_name" />
|
||||||
<br>
|
<br>
|
||||||
|
|
|
@ -14,7 +14,7 @@ include 'Header.php';
|
||||||
<div class="col-md-5">
|
<div class="col-md-5">
|
||||||
<form method="post" action="Script.php">
|
<form method="post" action="Script.php">
|
||||||
<legend>Recover password</legend>
|
<legend>Recover password</legend>
|
||||||
<input type="hidden" name="frm_recover_password" value="true"/>
|
<input type="hidden" name="form_recover_password" value="true"/>
|
||||||
Student number
|
Student number
|
||||||
<input type="text" name="sno" placeholder="Enter your student number" class="form-control" required="required" value="<?php echo htmlspecialchars($_SESSION['student_number']); ?>"> <br/>
|
<input type="text" name="sno" placeholder="Enter your student number" class="form-control" required="required" value="<?php echo htmlspecialchars($_SESSION['student_number']); ?>"> <br/>
|
||||||
Email
|
Email
|
||||||
|
|
Loading…
Reference in New Issue