Customizing the Subject Field in WordPress’ Notification Emails?

You can change them using a filter. The filter hooks you want to use are: For the first email message (confirming they really want to reset the password): ‘retrieve_password_title’ ‘retrieve_password_message’ For the follow-up email message (sending the new username and password): ‘password_reset_title’ ‘password_reset_message’ Update: To create and use these filters, put the following or similar … Read more

Overriding the default WP Multisite notification e-mail

I was able to override the multi-site notification email by adding these: remove_filter(‘wpmu_signup_user_notification_email’,’admin_created_user_email’); add_filter(‘wpmu_signup_user_notification_email’,<function_name_here>); add_filter(‘wpmu_signup_user_notification’,<function_name_here>); add_filter(‘wpmu_signup_user_notification_subject’,<function_name_here>); Adding the three filters at bottom i.e. email,notification and subject allows you to override the content and the subject of the email.

Sends out email to admin

No need for plugin here are a few lines of code you can modify and paste in your themes functions.php file and you will get a new email whenever a post is published: add_action(‘publish_post’, ‘send_admin_email’); function send_admin_email($post_id){ $to = ‘[email protected]’; $subject=”mail subject here”; $message = “your message here ex: new post published at: “.get_permalink($post_id); wp_mail($to, … Read more

Custom admin email for new user registration

Yes, you can Change email address by using wp_mail function. You can check this how to do this http://www.butlerblog.com/2011/07/14/changing-the-wp_mail-from-address-with-a-plugin/ Use this plugin for user management it supports email address when new user registers https://wordpress.org/plugins/wp-members/ Use this code in your functions.php file. function so174837_registration_email_alert( $user_id ) { $user = get_userdata( $user_id ); $email = $user->user_email; $message … Read more

How to set up User email verification after Signup?

You can use user_register hook add_action( ‘user_register’, ‘my_registration’, 10, 2 ); function my_registration( $user_id ) { // get user data $user_info = get_userdata($user_id); // create md5 code to verify later $code = md5(time()); // make it into a code to send it to user via email $string = array(‘id’=>$user_id, ‘code’=>$code); // create the activation code … Read more

Sending all emails using SMTP

You are trying with your Gmail mail server and it’s blocked from Gmail not form your host. Enable Gmail less secure apps into your Gmail account. If you want to allow access anyway, follow these steps: 1) Go to the Less secure apps section of your Google Account. 2) Turn on Allow less secure apps. … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)