diff --git a/lam/lib/modules.inc b/lam/lib/modules.inc
index 4f33422f..aa28136b 100644
--- a/lam/lib/modules.inc
+++ b/lam/lib/modules.inc
@@ -1266,62 +1266,63 @@ class accountContainer {
*/
private function printPasswordPromt($errors) {
$this->printPageHeader();
- // print error messages
+ echo "
type . "list-bright\">\n";
+ $container = new htmlTable();
+ // title
+ $container->addElement(new htmlSpacer(null, '5px'), true);
+ $titleContainer = new htmlTable();
+ $titleContainer->colspan = 3;
+ $titleContainer->addElement(new htmlSpacer('5px', null));
+ $titleContainer->addElement(new htmlOutputText(_("Set password")));
+ $titleContainer->addElement(new htmlHelpLink('404'), true);
+ $container->addElement($titleContainer, true);
+ $container->addElement(new htmlSpacer(null, '20px'), true);
+ // error messages
for ($i = 0; $i < sizeof($errors); $i++) {
- call_user_func_array('StatusMessage', $errors[$i]);
+ $text = '';
+ if (isset($errors[$i][2])) $text = $errors[$i][2];
+ $params = array();
+ if (isset($errors[$i][3])) $params = $errors[$i][3];
+ $message = new htmlStatusMessage($errors[$i][0], $errors[$i][1], $text, $params);
+ $message->colspan = 3;
+ $container->addElement($message, true);
}
- // create module menu
- echo "
type."list\" border=0 width=\"100%\" style=\"border-collapse: collapse;\">\n";
- echo "type . "list-bright\">";
- echo " | \n";
- echo "" . _("Set password") . " | ";
- echo "\n";
- printHelpLink(getHelp(null, 404), 404);
- echo " | | \n";
- echo "
type . "list-bright\">\n";
- echo " \n";
- echo " |
\n";
- echo "type . "list-bright\">\n";
- echo "\n";
- echo " |
\n";
- echo "
\n";
+ $moduleContainer->colspan = 5;
+ $container->addElement($moduleContainer, true);
+ $container->addElement(new htmlSpacer(null, '10px'), true);
+ // password fields
+ $container->addElement(new htmlOutputText(_('Password')));
+ $pwdInput1 = new htmlInputField('newPassword1');
+ $pwdInput1->setIsPassword(true);
+ $container->addElement($pwdInput1, true);
+ $container->addElement(new htmlOutputText(_('Repeat password')));
+ $pwdInput2 = new htmlInputField('newPassword2');
+ $pwdInput2->setIsPassword(true);
+ $container->addElement($pwdInput2, true);
+ $container->addElement(new htmlSpacer(null, '10px'), true);
+ // buttons
+ $buttonContainer = new htmlTable();
+ $buttonContainer->colspan = 3;
+ $buttonContainer->addElement(new htmlButton('setNewPasswordOk', _('Ok')));
+ $buttonContainer->addElement(new htmlButton('setNewPasswordCancel', _('Cancel')));
+ $buttonContainer->addElement(new htmlButton('setNewPasswordRandom', _('Set random password')));
+ $container->addElement($buttonContainer);
+ // generate HTML
+ $tabindex = 1;
+ parseHtml(null, $container, array(), false, $tabindex, $this->type);
// set focus on password field
echo "\n";
+ echo "
\n";
$this->printPageFooter();
}