Code snippet to change notification of new users

Fully Managed UK Hosting – Only £1+VAT till 1st Jan 2021 on Shared, Reseller and Dedicated Hosting! …. read more ….

Example plugin to set admin notification of new users. In this case it uses the first user defined as shop_manager role

 * Plugin Name:       Notify New Users to Shop Manager
 * Plugin URI:
 * Description:       Needs Woo Commerce of Course
 * Version:           1.0
 * Author:            Fullworks
 * Author URI:
 * License:           GPL-3.0+
 * License URI:

function admin_email_callback( $wp_new_user_notification_email,  $user,  $blogname ) {
    $shopmanager = get_users( array( 'role' => 'shop_manager' ) );
// set the to: the first shop manager email.
    $wp_new_user_notification_email['to'] = $shopmanager[0]->user_email;
    return $wp_new_user_notification_email;
add_filter( 'wp_new_user_notification_email_admin', 'admin_email_callback', 10, 3 );

Download this as a plugin from fullworks ->

[Next] Find out where to host WordPress [Read the full article…]

, ,

Leave a Reply

Your email address will not be published.