diff options
author | rxu <rxu@mail.ru> | 2015-01-22 23:10:05 +0700 |
---|---|---|
committer | rxu <rxu@mail.ru> | 2015-01-22 23:10:05 +0700 |
commit | e08cd70a89b5efcd303a14b13d827d063528937f (patch) | |
tree | af8a5d554c542902519460a8681967e0d3a4348c /phpBB/includes/ucp/ucp_profile.php | |
parent | 40ab75478ed7427985e4d147eb6573ce8bb351fc (diff) | |
download | forums-e08cd70a89b5efcd303a14b13d827d063528937f.tar forums-e08cd70a89b5efcd303a14b13d827d063528937f.tar.gz forums-e08cd70a89b5efcd303a14b13d827d063528937f.tar.bz2 forums-e08cd70a89b5efcd303a14b13d827d063528937f.tar.xz forums-e08cd70a89b5efcd303a14b13d827d063528937f.zip |
[ticket/13535] Add core event to allow modifying account settings on editing
Add ucp_profile.php core event to allow modifying account settings on editing.
PHPBB3-13535
Diffstat (limited to 'phpBB/includes/ucp/ucp_profile.php')
-rw-r--r-- | phpBB/includes/ucp/ucp_profile.php | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/phpBB/includes/ucp/ucp_profile.php b/phpBB/includes/ucp/ucp_profile.php index a876d0133a..436023a4a2 100644 --- a/phpBB/includes/ucp/ucp_profile.php +++ b/phpBB/includes/ucp/ucp_profile.php @@ -54,6 +54,17 @@ class ucp_profile 'password_confirm' => $request->variable('password_confirm', '', true), ); + /** + * Modify user registration data on editing account settings in UCP + * + * @event core.ucp_profile_reg_details_data + * @var array data Array with current or updated user registration data + * @var bool submit Flag indicating if submit button has been pressed + * @since 3.1.4-RC1 + */ + $vars = array('data', 'submit'); + extract($phpbb_dispatcher->trigger_event('core.ucp_profile_reg_details_data', compact($vars))); + add_form_key('ucp_reg_details'); if ($submit) @@ -200,6 +211,17 @@ class ucp_profile $sql_ary['user_newpasswd'] = ''; } + /** + * Modify user registration data before submitting it to the database + * + * @event core.ucp_profile_reg_details_sql_ary + * @var array data Array with current or updated user registration data + * @var array sql_ary Array with user registration data to submit to the database + * @since 3.1.4-RC1 + */ + $vars = array('data', 'sql_ary'); + extract($phpbb_dispatcher->trigger_event('core.ucp_profile_reg_details_sql_ary', compact($vars))); + if (sizeof($sql_ary)) { $sql = 'UPDATE ' . USERS_TABLE . ' |