Joomla User Profile Plugin
Hi
In my registration form i added the user profile plugin to collect other user informations, what i want to know if possible is how to add these fields to the Admin notification email that actually shows only the username and name of the registered user.
Thanks
In my registration form i added the user profile plugin to collect other user informations, what i want to know if possible is how to add these fields to the Admin notification email that actually shows only the username and name of the registered user.
Thanks
//Send Notification mail to administrators
This correlates to the same COM_USERS_EMAIL_REGISTERED_NOTIFICATION_TO_ADMIN_BODY option in either the /language/overrides/en-GB.override.ini or /administrator/language/en-GB/en-GB.com_users.ini file, which look like this:if (($params->get('useractivation') < 2) && ($params->get('mail_to_admin') == 1)) {
$emailSubject = JText::sprintf(
'COM_USERS_EMAIL_ACCOUNT_DETAILS',
$data['name'],
$data['sitename']
);
$emailBodyAdmin = JText::sprintf(
'COM_USERS_EMAIL_REGISTERED_NOTIFICATION_TO_ADMIN_BODY',
$data['name'],
$data['username'],
$data['siteurl']
);
COM_USERS_EMAIL_REGISTERED_NOTIFICATION_TO_ADMIN_BODY="Hello administrator, \n\nA new user '%s', username '%s', has registered at %s."
Unfortunately adding another %s variable replacement string in this setting does not allow for any new data to get passed, and it actually breaks the admin notifications from my testing. The other data entered in by the Joomla User Profile plugin ends up in the jos_user_profiles database table, instead of the jos_users table where the registration.php script is setup to pull from. So you would need to make some heavy modifications to the core Joomla scripts to get it to pull in other data for your admin notifications from what I can tell. Please let us know if you had any other questions at all. - Jacob