diff --git a/gosa-core/plugins/personal/generic/main.inc b/gosa-core/plugins/personal/generic/main.inc
index aeec45657a8c667767e17e8c67ac02e23ebce896..0ab96b0debdec1d25068019169992f21b7f8eb0a 100644 (file)
<?php
/*
- This code is part of GOsa (https://gosa.gonicus.de)
- Copyright (C) 2003 Cajus Pollmeier
-
- This program is free software; you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation; either version 2 of the License, or
- (at your option) any later version.
-
- This program is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- GNU General Public License for more details.
-
- You should have received a copy of the GNU General Public License
- along with this program; if not, write to the Free Software
- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ * This code is part of GOsa (http://www.gosa-project.org)
+ * Copyright (C) 2003-2008 GONICUS GmbH
+ *
+ * ID: $$Id$$
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
-
/* Preset display */
$display = "";
$lock_msg = "";
/* Empty password is not permitted by default. */
if ($_POST['new_password'] == ""){
- $message[]= _("The password you've entered as 'New password' is empty.");
+ $message[]= msgPool::required(_("New password"));
}
}
if (count($message) != 0){
/* Show error message and continue editing */
- show_errors ($message);
+ msg_dialog::displayChecks($message);
$display.= $smarty->fetch(get_template_path('password.tpl', TRUE));
return ($display);
}
} else {
/* Missing permissions, show message */
- print_red (_("You are not allowed to set your password!"));
+ msg_dialog::display(_("Error"), _("You have no permission to set your password!"), ERROR_DIALOG);
}
del_lock ($ui->dn);
} else {
/* Errors found, show message */
- show_errors ($message);
+ msg_dialog::displayChecks($message);
}
}
/* Are we in edit mode? */
if (session::is_set('edit')){
- $display.= "<input type=submit name=\"edit_finish\" style=\"width:80px\" value=\""._("Ok")."\">\n";
+ $display.= "<input type=submit name=\"edit_finish\" style=\"width:80px\" value=\"".msgPool::okButton()."\">\n";
$display.= " ";
- $display.= "<input type=submit name=\"edit_cancel\" value=\""._("Cancel")."\">\n";
+ $display.= "<input type=submit name=\"edit_cancel\" value=\"".msgPool::cancelButton()."\">\n";
- $info= "<img class=\"center\" alt=\"\" align=\"middle\" src=\"".get_template_path('images/closedlock.png').
+ $info= "<img class=\"center\" alt=\"\" align=\"middle\" src=\"".get_template_path('images/lists/locked.png').
"\"> ".$ui->dn." ";
} else {
/* 'viewid' may be set by i.e. the phonelist plugin. This
means that we want to go back... */
if (isset ($viewid)){
- $str= _("Back");
+ $str= msgPool::backButton();
$fn = "back";
} else {
- $str= _("Edit");
+ $str= msgPool::editButton();
$fn = "edit";
- $info= "<img class=\"center\" alt=\"\" align=\"middle\" src=\"".get_template_path('images/openlock.png').
+ $info= "<img class=\"center\" alt=\"\" align=\"middle\" src=\"".get_template_path('images/lists/unlocked.png').
"\"> ".$ui->dn." ";
}
/* Only display edit button if there is at least one attribute editable */
- if(preg_match("/w/",$ui->get_permissions($ui->dn,"users/user"))){
+ if(preg_match("/r/",$ui->get_permissions($ui->dn,"users/user"))){
if ($fn == "edit"){
- $info.= "<img class=\"center\" alt=\"\" align=\"middle\" src=\"".get_template_path('images/lamp.png')."\"> ".
- _("Click the 'Edit' button below to change informations in this dialog");
+ $info.= "<img class=\"center\" alt=\"\" align=\"middle\" src=\"".get_template_path('images/lists/on.png')."\"> ".
+ msgPool::clickEditToChange();
$display.= "<input type=submit name=\"$fn\" value=\"$str\">\n";
}
}
}
/* Page header*/
- $display= print_header(get_template_path('images/personal.png'),
+ $display= print_header(get_template_path('plugins/generic/images/plugin.png'),
_("Generic user information"), $info).$display;
}