-
AuthorPosts
-
July 1, 2016 at 12:40 pm #655713
Hi,
I’m using WP Registration Pro in my Enfold theme. Since their support is really non existing, I hope you guys can help me out because it’s kinda urgent. In the new user notification email to the Admin I would like to have all the fields displayed that have to be filled out during registration. To achieve this, I tried to add the following statment as a test in the child functions.php but that doesn’t work.
if ( !function_exists('wp_new_user_notification') ) { function wp_new_user_notification( $user_id, $plaintext_pass = '' ) { $user = new WP_User($user_id); $user_login = stripslashes($user->user_login); $user_email = stripslashes($user->user_email); $user_first_name = get_user_meta( $user_id, 'first_name', true ); $user_last_name = get_user_meta( $user_id, 'last_name', true ); $fullname = ($user_first_name." ". $user_last_name); // Admin Notification Email $message = sprintf(__('New user registration on your website %s:'), get_option('blogname')) . "\r\n\r\n"; $message .= sprintf(__('Username: %s'), $user_login) . "\r\n\r\n"; $message .= sprintf(__('E-mail: %s'), $user_email) . "\r\n"; $message .= sprintf(__('Full Name: %s'), $fullname) . "\r\n"; @wp_mail(get_option('admin_email'), sprintf(__('%s - New User Registration'), get_option('blogname')), $message); if ( empty($plaintext_pass) ) return; // Users Notification Email $message = "Hi $fullname," . "\r\n\r\n"; $message .= sprintf(__("Thanks for registering your details at %s! website, your user login details are below:"), get_option('blogname')) . "\r\n\r\n"; $message .= wp_login_url() . "\r\n"; $message .= sprintf(__('Username: %s'), $user_login). "\r\n"; $message .= sprintf(__('Password: %s'), $plaintext_pass). "\r\n\r\n"; $message .= sprintf(__('If you have any questions or problems, please contact us at %s.'), get_option('admin_email')) . "\r\n\r\n"; $message .= __('Thank you,'). "\r\n\r\n"; $message .= get_option('blogname'). "\r\n"; $message .= get_option('home'). "\r\n\r\n"; wp_mail($user_email, sprintf(__('%s - Username & Password'), get_option('blogname')), $message); } }
Any tips on how to solve this? I’m more than happy to give you admin access.
Thanks in advance!
July 1, 2016 at 2:03 pm #655776Hey steviger,
I’m sorry, but we can’t help you in this case. We can’t support every 3rd party plugin existing, as written in our support policy. Is plugin’s author can’t help you, then I would go for a different plugin. You could also hire a freelance developer for this job (to make it compatible etc.): kriesi.at/contact/customization
Best regards,
AndyJuly 1, 2016 at 2:09 pm #655780Hi Andy,
I understand. Thanks anyway.
Cheers
-
AuthorPosts
- The topic ‘Adding extra fields in new user notification emails’ is closed to new replies.