exit(''); } if (pathos_permissions_check('user_management', pathos_core_makeLocation('administrationmodule'))) { if (!defined('SYS_USERS')) { require_once BASE . 'subsystems/users.php'; } if (!defined('SYS_FORMS')) { require_once BASE . 'subsystems/forms.php'; } pathos_forms_initialize(); $u = pathos_users_getUserById($_GET['id']); if ($u == null) { $u->is_admin = 0; $u->is_acting_admin = 0; } $u = pathos_users_getFullProfile($u); $form = pathos_users_form($u); $form->meta('module', 'administrationmodule'); $form->meta('action', 'umgr_saveuser'); if ($user->is_admin == 1 && $u->is_admin == 0) { // Super user editting a 'lesser' user. pathos_lang_loadDictionary('modules', 'administrationmodule'); $form->registerBefore('submit', 'is_acting_admin', TR_ADMINISTRATIONMODULE_ISADMIN, new checkboxcontrol($u->is_acting_admin, true)); } $template = new template('administrationmodule', '_umgr_editprofile', $loc); $template->assign('form_html', $form->toHTML()); $template->assign('is_edit', isset($u->id) ? 1 : 0); $template->output(); } else { echo SITE_403_HTML; }
# # Free Software Foundation, Inc., # 59 Temple Place, # Suite 330, # Boston, MA 02111-1307 USA # # $Id: createuser.php,v 1.9 2005/04/18 15:50:24 filetreefrog Exp $ ################################################## if (!defined('PATHOS')) { exit(''); } if (SITE_ALLOW_REGISTRATION == 1) { if (!defined('SYS_USERS')) { require_once 'subsystems/users.php'; } if (!defined('SYS_FORMS')) { require_once 'subsystems/forms.php'; } pathos_forms_initialize(); $form = pathos_users_form(null); $form->meta('module', 'loginmodule'); $form->meta('action', 'saveuser'); if (SITE_USE_CAPTCHA && PATHOS_HAS_GD) { pathos_lang_loadDictionary('modules', 'loginmodule'); $form->registerBefore('submit', null, '', new htmlcontrol(sprintf(TR_LOGINMODULE_CAPTCHADESC, '<img src="' . PATH_RELATIVE . 'captcha.php" />'), false)); $form->registerBefore('submit', 'captcha_string', '', new textcontrol('', 6)); } $template = new template('loginmodule', '_form_createUser', $loc); $template->assign('form_html', $form->toHTML()); $template->output(); }