diff options
author | David Tobin <dtobin08@gmail.com> | 2012-07-05 02:47:49 +0100 |
---|---|---|
committer | Nathan Guse <nathaniel.guse@gmail.com> | 2013-02-04 23:10:10 -0600 |
commit | 293b65e3efbf94f6521acebe1b9f3e7bbca20286 (patch) | |
tree | 11fdc3c88318dbea7b8bb381be6395628b95cbc5 /phpBB/adm/index.php | |
parent | 996f1abee3640848dbcb00062646b681fe5e58af (diff) | |
download | forums-293b65e3efbf94f6521acebe1b9f3e7bbca20286.tar forums-293b65e3efbf94f6521acebe1b9f3e7bbca20286.tar.gz forums-293b65e3efbf94f6521acebe1b9f3e7bbca20286.tar.bz2 forums-293b65e3efbf94f6521acebe1b9f3e7bbca20286.tar.xz forums-293b65e3efbf94f6521acebe1b9f3e7bbca20286.zip |
[ticket/10896] Adds email validation to email settings in ACP
Adds a new validation type to the ACP validate_config_vars function
and implements it on the board_contact and board_email settings.
PHPBB3-10896
Diffstat (limited to 'phpBB/adm/index.php')
-rw-r--r-- | phpBB/adm/index.php | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/phpBB/adm/index.php b/phpBB/adm/index.php index 2e4089c02e..2da8a130cc 100644 --- a/phpBB/adm/index.php +++ b/phpBB/adm/index.php @@ -449,6 +449,13 @@ function validate_config_vars($config_vars, &$cfg_array, &$error) } break; + case 'email': + if (!preg_match('/^' . get_preg_expression('email') . '$/i', $cfg_array[$config_name])) + { + $error[] = $user->lang['EMAIL_INVALID']; + } + break; + // Absolute path case 'script_path': if (!$cfg_array[$config_name]) |