getArg('pagename'); if ($request->isActionPage($request->getArg('pagename')) and $isForm and $plugin == _("PreferencesInfo")) { $isForm = false; } $time = time(); $user =& $request->getUser(); $pref =& $request->_prefs; if (!$pref) return; $offset = $pref->get('timeOffset'); $serverTime = $time - $offset * 3600; if ( $isForm ) $timeOffsetInput = HTML::input(array('type' => "text", 'size' => 6, 'maxlength' => 6, 'name' => "pref[timeOffset]", 'class' => "numeric", 'value' => $offset)); else $timeOffsetInput = $pref->get('timeOffset'); $RelativeDatesCB = HTML::input(array('type' => 'checkbox', 'name' => 'pref[relativeDates]', 'value' => '1', 'checked' => (bool) $pref->get('relativeDates'))); $NoLinkIconsCB = HTML::input(array('type' => 'checkbox', 'name' => 'pref[noLinkIcons]', 'value' => '1', 'checked' => (bool) $pref->get('noLinkIcons'))); $GoogleLinkCB = HTML::input(array('type' => 'checkbox', 'name' => 'pref[googleLink]', 'value' => '1', 'checked' => (bool) $pref->get('googleLink'))); $DoubleClickCB = HTML::input(array('type' => 'checkbox', 'name' => 'pref[doubleClickEdit]', 'value' => '1', 'checked' => (bool) $pref->get('doubleClickEdit'))); if (!function_exists('selectedOption')) { function selectedOption ($value, $label = false) { return HTML::option(array('value' => $value,'selected'=>"selected"), ($label ? $label : $value) . "\n"); } function unselectedOption ($value, $label = false) { return HTML::option(array('value' => $value), ($label ? $label : $value) . "\n"); } } $SelectThemes = ''; $SelectLanguages = ''; $SelectThemesDesc = ''; $SelectLanguagesDesc = ''; if ( $isForm ) { $SelectOptions = HTML(); if (!empty($available_themes) and is_array($available_themes)) { if (!$pref->get('theme') or $pref->get('theme') == THEME) $SelectOptions->pushContent(selectedOption("",_(""))); else $SelectOptions->pushContent(unselectedOption("",_(""))); foreach ($available_themes as $theme) { if ($theme == $pref->get('theme') and $theme != THEME) $SelectOptions->pushContent(selectedOption($theme)); else $SelectOptions->pushContent(unselectedOption($theme)); } $SelectThemes = HTML::select(array('name' => "pref[theme]",'id' => 'theme'), $SelectOptions); $SelectThemesDesc = _("Personal theme:"); } $SelectOptions = HTML(); if (!empty($available_languages) and is_array($available_languages)) { if (!$pref->get('lang') or $pref->get('lang') == DEFAULT_LANGUAGE) $SelectOptions->pushContent(selectedOption("",_(""))); else $SelectOptions->pushContent(unselectedOption("",_(""))); foreach ($available_languages as $lang) { if ($lang == $pref->get('lang') and $lang != DEFAULT_LANGUAGE) $SelectOptions->pushContent(selectedOption($lang)); else $SelectOptions->pushContent(unselectedOption($lang)); } $SelectLanguages = HTML::select(array('name' => "pref[lang]",'id' => 'lang'), $SelectOptions); $SelectLanguagesDesc = _("Personal language:"); } else { if ($SelectThemes == '') { $appearance = false; $SelectThemesDesc = ''; $SelectLanguagesDesc = ''; } } } else { $SelectThemesDesc = _("Personal theme:"); $SelectLanguagesDesc = _("Personal language:"); $SelectThemes = $pref->get('theme'); $SelectLanguages = $pref->get('lang'); } if ($errmsg) $msg = HTML(HTML::h4(array('class' => 'errors'), $errmsg),HTML::hr()); ?> = $errmsg ?> = fmt("User preferences for user '%s':", $user->UserName()) ?> _authmethod : @$user->auth_how; ?> = HTML::pre(sprintf("%12s: [% 10s] %s\n",_("UserId"),$pref->get('userid'), " from " . $authmethod), sprintf("%12s: [% 10s] %16s: [% 10s] | %8s: [%2s]\n","getId",$user->getId(),"getAuthenticatedId",$user->getAuthenticatedId(),"isSignedIn", $user->isSignedIn()), //sprintf("%12s: [% 10s]\n",_("Password"),empty($pref->get('passwd')) ? _("") : _("")), sprintf("%12s: [% 10s] %15s: [% 8s]\n", _("Auth Level"),$user->_level,_("Auth Method"),$authmethod), sprintf("%12s: [% 10s]\n",_("HomePage"),$user->hasHomePage() ? (ENABLE_USER_NEW ? $user->_HomePagehandle->_pagename : $user->_homepage->_pagename ) : ''), sprintf("%12s: [% 10s]\n",_("E-Mail"),$pref->get('email')), //sprintf("%12s: [% 10s]\n",_("Notify"),$pref->get('notifyPages')), sprintf("%12s: [% 10s] %16s: [% 10s] \n",_("Theme"), $pref->get('theme'), _("Current Theme"),$WikiTheme->_name), sprintf("%12s: [% 10s] %16s: [% 10s] \n",_("Language"),$pref->get('lang'),_("Current Language"),$GLOBALS['LANG']) ) ?> mayChangePass()) { ?> = ($request->getPref('passwd') ? _("Change Password") : _("Set Password")) ?> =_("New password")?>: =_("Type it again")?>: =_("E-mail")?> =_("Your E-Mail:")?> '= $pref->get('email') ?>' = _("Status:") ?> get('emailVerified')) { ?> = _("Email verified.") ?> = _("Email not yet verified.") ?> =_("Note, that user accounts with bouncing emails will be disabled.")?> =_("Get an email notification at changes of the following pages:")?> =$pref->get('notifyPages')?> =_("Enter pages seperated by space or comma. Wildcards (fileglobbing) allowed.")?> =$pref->get('notifyPages')?> =_("Appearance")?> =_("Here you can override site-specific default values.") ?> = _("Currently not recommended!") ?> and . */ ?> =$SelectThemesDesc?> = $SelectThemes ?> =_("System default:")?> = THEME ?> =$SelectLanguagesDesc?> = $SelectLanguages ?> =_("System default:")?> = DEFAULT_LANGUAGE ?> =fmt("Hide %s:", WikiLink("LinkIcons"))?> =$NoLinkIconsCB?> =_("Hide or show LinkIcons (if supported by the current theme). Useful for text-only browsers or slow connections.")?> =fmt("Add %s:", WikiLink("GoogleLink"))?> =$GoogleLinkCB?> =fmt("Add Google links to unknown pages behind the '?', and the create action behind the pagename instead. See %s.", WikiLink("MeatBall:GooglePrompt"))?> =fmt("Enable DoubleClick Edit")?> =$DoubleClickCB?> =fmt("Enabled makes it hard to double-click words and sentences for cut and paste. See %s.", WikiLink("PhpWiki:DoubleClickToEditPage"))?> =_("Edit Area Size")?> =_("Height")?>: =$pref->get('editHeight')?> =_("Width")?>: =$pref->get('editWidth')?> =_("Note that many browsers will automatically adjust the width of the editing area so that it fills the browser window. In this case, the width preference will be ignored.")?> =_("Time Zone")?> =fmt("Add %s hours to the server's local time when reporting times.", $timeOffsetInput)?> =fmt("The current time at the server is %s.", HTML::strong($WikiTheme->formatDateTime($serverTime)))?> =fmt("With the current offset, this would be reported as %s.", HTML::strong($WikiTheme->formatDateTime($time)))?> =_("Date Format")?> =_("Show relative dates using 'Today' and 'Yesterday'")?>: = $RelativeDatesCB ?> =Button("submit:", _("Update Preferences"), 'wikiadmin')?> =Button("submit:delete", _("Reset Preferences"), 'wikiadmin')?> =Button("submit:cancel", _("Cancel"), 'button')?> = HiddenInputs($request->getArgs(), false, array('pref')) ?>
=_("Note, that user accounts with bouncing emails will be disabled.")?>
=$pref->get('notifyPages')?>
=_("Enter pages seperated by space or comma. Wildcards (fileglobbing) allowed.")?>
=_("Hide or show LinkIcons (if supported by the current theme). Useful for text-only browsers or slow connections.")?>
=fmt("Add Google links to unknown pages behind the '?', and the create action behind the pagename instead. See %s.", WikiLink("MeatBall:GooglePrompt"))?>
=fmt("Enabled makes it hard to double-click words and sentences for cut and paste. See %s.", WikiLink("PhpWiki:DoubleClickToEditPage"))?>
=_("Note that many browsers will automatically adjust the width of the editing area so that it fills the browser window. In this case, the width preference will be ignored.")?>
=fmt("Add %s hours to the server's local time when reporting times.", $timeOffsetInput)?>
=fmt("The current time at the server is %s.", HTML::strong($WikiTheme->formatDateTime($serverTime)))?> =fmt("With the current offset, this would be reported as %s.", HTML::strong($WikiTheme->formatDateTime($time)))?>
=_("Show relative dates using 'Today' and 'Yesterday'")?>: = $RelativeDatesCB ?>
=Button("submit:", _("Update Preferences"), 'wikiadmin')?> =Button("submit:delete", _("Reset Preferences"), 'wikiadmin')?> =Button("submit:cancel", _("Cancel"), 'button')?>