Update: Formatting and code cleanup in processor and config files
This commit is contained in:
@@ -2780,7 +2780,7 @@ function url($page) {
|
|||||||
'google_validate_login' => '/src/api/google_validate_login.php',
|
'google_validate_login' => '/src/api/google_validate_login.php',
|
||||||
|
|
||||||
// Processors
|
// Processors
|
||||||
'validate_login' => '/src/processors/validate_login.php',
|
'validate_login' => '/validate_login.php',
|
||||||
'register_user' => '/src/processors/register_user.php',
|
'register_user' => '/src/processors/register_user.php',
|
||||||
'process_application' => '/src/processors/process_application.php',
|
'process_application' => '/src/processors/process_application.php',
|
||||||
'process_booking' => '/src/processors/process_booking.php',
|
'process_booking' => '/src/processors/process_booking.php',
|
||||||
|
|||||||
@@ -33,11 +33,11 @@ if (isset($_POST['signature'])) {
|
|||||||
|
|
||||||
// Create a file path for the signature image
|
// Create a file path for the signature image
|
||||||
$fileName = 'signature_' . $user_id . '.png';
|
$fileName = 'signature_' . $user_id . '.png';
|
||||||
$filePath = $rootPath . '/src/processors/uploads/signatures/' . $fileName;
|
$filePath = $rootPath . '/uploads/signatures/' . $fileName;
|
||||||
|
|
||||||
// Ensure the directory exists
|
// Ensure the directory exists
|
||||||
if (!is_dir($rootPath . '/src/processors/uploads/signatures')) {
|
if (!is_dir($rootPath . '/uploads/signatures')) {
|
||||||
mkdir($rootPath . '/src/processors/uploads/signatures', 0777, true);
|
mkdir($rootPath . '/uploads/signatures', 0777, true);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Save the image file
|
// Save the image file
|
||||||
@@ -49,7 +49,7 @@ if (isset($_POST['signature'])) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Store relative path for HTML display
|
// Store relative path for HTML display
|
||||||
$display_path = 'src/processors/uploads/signatures/' . $fileName;
|
$display_path = '/uploads/signatures/' . $fileName;
|
||||||
|
|
||||||
// Update the signature and indemnity acceptance in the membership application table
|
// Update the signature and indemnity acceptance in the membership application table
|
||||||
$stmt = $conn->prepare("UPDATE membership_application SET sig = ?, accept_indemnity = 1 WHERE user_id = ?");
|
$stmt = $conn->prepare("UPDATE membership_application SET sig = ?, accept_indemnity = 1 WHERE user_id = ?");
|
||||||
|
|||||||
@@ -38,7 +38,7 @@ if ($_SERVER['REQUEST_METHOD'] === 'POST') {
|
|||||||
exit;
|
exit;
|
||||||
}
|
}
|
||||||
|
|
||||||
$target_dir = $rootPath . "/src/processors/uploads/pop/";
|
$target_dir = $rootPath . "/uploads/pop/";
|
||||||
// Use EFT ID as filename instead of random filename
|
// Use EFT ID as filename instead of random filename
|
||||||
$filename = $eft_id . '.pdf';
|
$filename = $eft_id . '.pdf';
|
||||||
$target_file = $target_dir . $filename;
|
$target_file = $target_dir . $filename;
|
||||||
|
|||||||
Reference in New Issue
Block a user