Line | |
---|
1 | <?php |
---|
2 | if (!defined('CONTACT_FORM_PATH')) die('Hacking attempt!'); |
---|
3 | |
---|
4 | global $template, $page; |
---|
5 | |
---|
6 | $page['tab'] = (isset($_GET['tab'])) ? $_GET['tab'] : 'config'; |
---|
7 | |
---|
8 | // tabsheet |
---|
9 | include_once(PHPWG_ROOT_PATH.'admin/include/tabsheet.class.php'); |
---|
10 | $tabsheet = new tabsheet(); |
---|
11 | $tabsheet->add('config', l10n('Configuration'), CONTACT_FORM_ADMIN . '-config'); |
---|
12 | $tabsheet->add('emails', l10n('E-mails'), CONTACT_FORM_ADMIN . '-emails'); |
---|
13 | $tabsheet->select($page['tab']); |
---|
14 | $tabsheet->assign(); |
---|
15 | |
---|
16 | // include page |
---|
17 | include(CONTACT_FORM_PATH . 'admin/' . $page['tab'] . '.php'); |
---|
18 | |
---|
19 | if (!$conf['ContactForm_ready']) |
---|
20 | { |
---|
21 | $page['errors'][] = l10n('No active email address'); |
---|
22 | } |
---|
23 | |
---|
24 | // template |
---|
25 | $template->assign(array( |
---|
26 | 'CONTACT_FORM_PATH' => CONTACT_FORM_PATH, |
---|
27 | 'CONTACT_FORM_ADMIN' => CONTACT_FORM_ADMIN, |
---|
28 | )); |
---|
29 | |
---|
30 | $template->assign_var_from_handle('ADMIN_CONTENT', 'contact_form'); |
---|
Note: See
TracBrowser
for help on using the repository browser.