[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Phpgroupware-cvs] preferences changepassword.php
From: |
Johan Gunnarsson |
Subject: |
[Phpgroupware-cvs] preferences changepassword.php |
Date: |
Tue, 12 Jun 2007 09:51:51 +0000 |
CVSROOT: /sources/phpgroupware
Module name: preferences
Changes by: Johan Gunnarsson <johang> 07/06/12 09:51:51
Modified files:
. : changepassword.php
Log message:
* Patch #6002: Fix NOTICEs
CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/preferences/changepassword.php?cvsroot=phpgroupware&r1=1.44&r2=1.45
Patches:
Index: changepassword.php
===================================================================
RCS file: /sources/phpgroupware/preferences/changepassword.php,v
retrieving revision 1.44
retrieving revision 1.45
diff -u -b -r1.44 -r1.45
--- changepassword.php 18 Sep 2006 09:34:00 -0000 1.44
+++ changepassword.php 12 Jun 2007 09:51:50 -0000 1.45
@@ -6,7 +6,7 @@
* @copyright Copyright (C) 2000-2005 Free Software Foundation, Inc.
http://www.fsf.org/
* @license http://www.gnu.org/licenses/gpl.html GNU General Public
License
* @package preferences
- * @version $Id: changepassword.php,v 1.44 2006/09/18 09:34:00 sigurdne
Exp $
+ * @version $Id: changepassword.php,v 1.45 2007/06/12 09:51:50 johang
Exp $
*/
$GLOBALS['phpgw_info']['flags'] = array(
@@ -20,10 +20,10 @@
*/
include('../header.inc.php');
- $n_passwd = $_POST['n_passwd'];
- $n_passwd_2 = $_POST['n_passwd_2'];
+ $n_passwd = isset($_POST['n_passwd']) && $_POST['n_passwd'] ?
$_POST['n_passwd'] : '';
+ $n_passwd_2 = isset($_POST['n_passwd_2']) && $_POST['n_passwd_2'] ?
$_POST['n_passwd_2'] : '';
- if (! $GLOBALS['phpgw']->acl->check('changepassword', 1) ||
$_POST['cancel'])
+ if (! $GLOBALS['phpgw']->acl->check('changepassword', 1) ||
(isset($_POST['cancel']) && $_POST['cancel']))
{
$GLOBALS['phpgw']->redirect_link('/preferences/index.php');
$GLOBALS['phpgw']->common->phpgw_exit();
@@ -44,8 +44,10 @@
. 'need to be done manually.'));
}
- if ($_POST['change'])
+ if (isset($_POST['change']) && $_POST['change'])
{
+ $errors = array();
+
if ($n_passwd != $n_passwd_2)
{
$errors[] = lang('The two passwords are not the same');
@@ -56,7 +58,7 @@
$errors[] = lang('You must enter a password');
}
- if (is_array($errors))
+ if (count($errors))
{
$GLOBALS['phpgw']->common->phpgw_header();
echo parse_navbar();
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Phpgroupware-cvs] preferences changepassword.php,
Johan Gunnarsson <=