Skip to content

Commit

Permalink
fixed: header location
Browse files Browse the repository at this point in the history
  • Loading branch information
SilentSmeary committed Jan 20, 2025
1 parent e9c2bf0 commit df51ed0
Show file tree
Hide file tree
Showing 8 changed files with 16 additions and 12 deletions.
2 changes: 1 addition & 1 deletion admin/add/add_new_brand.php
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@

// Check for valid session and cookie
if (!isset($_SESSION['ssnlogin']) || !isset($_COOKIE['cookies_and_cream'])) {
header("Location: ../index.html");
header("Location: ../../index.html");
exit();
}

Expand Down
2 changes: 1 addition & 1 deletion admin/add/add_new_med.php
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@

// Check for valid session and cookie
if (!isset($_SESSION['ssnlogin']) || !isset($_COOKIE['cookies_and_cream'])) {
header("Location: ../index.html");
header("Location: ../../index.html");
exit();
}

Expand Down
2 changes: 1 addition & 1 deletion admin/staff/change_password.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

// Check for valid session and cookie
if (!isset($_SESSION['ssnlogin']) || !isset($_COOKIE['cookies_and_cream'])) {
header("Location: ../index.html");
header("Location: ../../index.html");
exit();
}

Expand Down
2 changes: 1 addition & 1 deletion admin/staff/create_user_data.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

// Check for valid session and cookie
if (!isset($_SESSION['ssnlogin']) || !isset($_COOKIE['cookies_and_cream'])) {
header("Location: ../index.html");
header("Location: ../../index.html");
exit();
}

Expand Down
6 changes: 3 additions & 3 deletions admin/staff/create_user_form.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

// Check for valid session and cookie
if (!isset($_SESSION['ssnlogin']) || !isset($_COOKIE['cookies_and_cream'])) {
header("Location: ../index.html");
header("Location: ../../index.html");
exit();
}

Expand Down Expand Up @@ -53,11 +53,11 @@
<br><br>
<div class='text-element'>Enter password: </div>
<div class='text-element-faded'>Example: Password123@#!!</div>
<input class="text_input" type="text" name="password" id="" required>
<input class="text_input" type="password" name="password" id="" required>
<br><br>
<div class='text-element'>Enter confirm password: </div>
<div class='text-element-faded'>Example: Password123@#!!</div>
<input class="text_input" type="text" name="c_password" id="" required>
<input class="text_input" type="password" name="c_password" id="" required>
<br><br>
<div class='text-element'>Select the user group: </div>
<div class='text-element-faded'>Example: Admin</div>
Expand Down
2 changes: 1 addition & 1 deletion admin/staff/delete_user.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

// Check for valid session and cookie
if (!isset($_SESSION['ssnlogin']) || !isset($_COOKIE['cookies_and_cream'])) {
header("Location: ../index.html");
header("Location: ../../index.html");
exit();
}

Expand Down
2 changes: 1 addition & 1 deletion admin/staff/staff_home.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

// Check for valid session and cookie
if (!isset($_SESSION['ssnlogin']) || !isset($_COOKIE['cookies_and_cream'])) {
header("Location: ../index.html");
header("Location: ../../index.html");
exit();
}

Expand Down
10 changes: 7 additions & 3 deletions edit_details/student_table.php
Original file line number Diff line number Diff line change
Expand Up @@ -81,14 +81,18 @@ class = "search_bar"
echo "<td>" . htmlspecialchars($value) . "</td>";
}
echo "<td class='big_table_td'>
<input type='checkbox' name='progress_ids[]' value='" . htmlspecialchars($student['student_id']) . "' checked>
</td>";
<div class='centered-form'>
<input type='checkbox' name='progress_ids[]' value='" . htmlspecialchars($student['student_id']) . "' checked>
</div>
</td>";
echo "</tr>";
}
echo "</table>";
echo "<button type='submit' name='finalize_progress'>Finalise Progress</button>";
echo '<br><br>';
echo "<button class='submit' type='submit' name='finalize_progress'>Finalise Progress</button>";
echo "</form>";
} else {

echo "<p>No students found in Year $selected_year.</p>";
}
} catch (PDOException $e) {
Expand Down

0 comments on commit df51ed0

Please sign in to comment.