|
2 | 2 |
|
3 | 3 | require_once("../../global/library.php");
|
4 | 4 |
|
| 5 | +use FormTools\Administrator; |
5 | 6 | use FormTools\Modules;
|
| 7 | +use FormTools\Settings; |
| 8 | +use FormTools\Modules\SubmissionAccounts\Admin; |
6 | 9 |
|
7 | 10 | $module = Modules::initModulePage();
|
8 | 11 |
|
9 | 12 | // for errors that prevent the usage of this page
|
10 | 13 | $main_error = false;
|
11 | 14 | $error = "";
|
12 | 15 |
|
13 |
| -$module_settings = ft_get_module_settings("", "submission_accounts"); |
14 |
| -$L = ft_get_module_lang_file_contents("submission_accounts"); |
| 16 | +$module_settings = $module->getSettings(); |
| 17 | +$L = $module->getLangStrings(); |
15 | 18 |
|
16 | 19 | // get the default settings
|
17 |
| -$settings = ft_get_settings(); |
| 20 | +$settings = Settings::get(); |
18 | 21 | $g_theme = $settings["default_theme"];
|
19 | 22 | $g_swatch = $settings["default_client_swatch"];
|
20 | 23 |
|
21 | 24 | // now, if there's a form ID available (e.g. passed to the page via GET or POST), see if the form has been
|
22 | 25 | // configured with submission accounts and if so, use the theme associated with the form
|
23 |
| -$form_id = ft_load_module_field("submission_accounts", "form_id", "form_id", ""); |
| 26 | +$form_id = Modules::loadModuleField("submission_accounts", "form_id", "form_id", ""); |
24 | 27 | $submission_account = array();
|
25 | 28 | if (!empty($form_id)) {
|
26 |
| - $submission_account = sa_get_submission_account($form_id); |
| 29 | + $submission_account = Admin::getSubmissionAccount($form_id); |
| 30 | + |
27 | 31 | if (isset($submission_account["form_id"]) && $submission_account["submission_account_is_active"] == "yes") {
|
28 | 32 | $g_theme = $submission_account["theme"];
|
29 | 33 | $g_swatch = $submission_account["swatch"];
|
|
46 | 50 | list($g_success, $g_message) = sa_send_password($form_id, $_POST);
|
47 | 51 | }
|
48 | 52 |
|
49 |
| -$admin_info = ft_get_admin_info(); |
| 53 | +$admin_info = Administrator::getAdminInfo(); |
50 | 54 | $admin_email = $admin_info["email"];
|
51 | 55 |
|
52 | 56 | $replacements = array("site_admin_email" => "<a href=\"mailto:$admin_email\">$admin_email</a>");
|
|
0 commit comments