From 6d8dbeda57e36280688ae790a99fc1e21122433b Mon Sep 17 00:00:00 2001 From: Cameron Date: Sat, 22 Dec 2012 00:59:32 -0800 Subject: [PATCH] Should fix Issue #64 (usersettings password issue) --- e107_core/shortcodes/batch/usersettings_shortcodes.php | 4 ++-- e107_handlers/form_handler.php | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/e107_core/shortcodes/batch/usersettings_shortcodes.php b/e107_core/shortcodes/batch/usersettings_shortcodes.php index 867251cec..c6cd5bab3 100755 --- a/e107_core/shortcodes/batch/usersettings_shortcodes.php +++ b/e107_core/shortcodes/batch/usersettings_shortcodes.php @@ -91,7 +91,7 @@ class usersettings_shortcodes extends e_shortcode if(!isset($pref['auth_method']) || $pref['auth_method'] == '' || $pref['auth_method'] == 'e107' || $pref['auth_method'] == '>e107') { - $options = array('size' => 40,'title'=>LAN_USET_23); + $options = array('size' => 40,'title'=>LAN_USET_23, 'required'=>0); return e107::getForm()->password('password1', '', 20, $options); } @@ -106,7 +106,7 @@ class usersettings_shortcodes extends e_shortcode if(!isset($pref['auth_method']) || $pref['auth_method'] == '' || $pref['auth_method'] == 'e107' || $pref['auth_method'] == '>e107') { - $options = array('size' => 40,'title'=>LAN_USET_23); + $options = array('size' => 40,'title'=>LAN_USET_23, 'required'=>0); return e107::getForm()->password('password2', '', 20, $options); } diff --git a/e107_handlers/form_handler.php b/e107_handlers/form_handler.php index 8d5fba1f6..34db7c2b9 100644 --- a/e107_handlers/form_handler.php +++ b/e107_handlers/form_handler.php @@ -737,7 +737,7 @@ class e_form } $options['pattern'] = vartrue($options['pattern'],'[\S]{4,}'); - $options['required'] = vartrue($options['required'], 1); + $options['required'] = varset($options['required'], 1); $options['class'] = vartrue($options['class'],'e-password'); $options = $this->format_options('text', $name, $options);