Skip to content

Commit

Permalink
Refactor POST handling.
Browse files Browse the repository at this point in the history
- Split into admin and user handlers, each admin page gets its own file now
- Enforce role access once for admin POST requests
- Automatically load POST logic for admin-based requests based on the referring page, otherwise automatically load all user request logic
- Add support for using custom POST handlers
  • Loading branch information
wrongecho committed Sep 29, 2024
1 parent 6363d26 commit 0c0cf2f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion post/admin/admin_settings_module.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
$config_module_enable_ticketing = intval($_POST['config_module_enable_ticketing']);
$config_module_enable_accounting = intval($_POST['config_module_enable_accounting']);
$config_client_portal_enable = intval($_POST['config_client_portal_enable']);
$config_whitelabel_key = $_POST['config_whitelabel_key'];
$config_whitelabel_key = sanitizeInput($_POST['config_whitelabel_key']);

mysqli_query($mysqli,"UPDATE settings SET config_module_enable_itdoc = $config_module_enable_itdoc, config_module_enable_ticketing = $config_module_enable_ticketing, config_module_enable_accounting = $config_module_enable_accounting, config_client_portal_enable = $config_client_portal_enable WHERE company_id = 1");

Expand Down

0 comments on commit 0c0cf2f

Please sign in to comment.