X

How to Customize Easy Digital Downloads User Verification Emails

Snippets by IsItWP

Are you looking for a way to customize Easy Digital Downloads user verification emails that you want to send out to your customers? While there’s probably a plugin for this, we have created a quick code snippet that you can use to customize Easy Digital Downloads user verification emails.

Instructions:

All you have to do is add this code to your theme’s functions.php file or in a site-specific plugin:

function jp_customize_verification_email( $message, $user_id ) {
	$user_data = get_userdata( $user_id );
	$url       = edd_get_user_verification_url( $user_id );
	$from_name = edd_get_option( 'from_name', wp_specialchars_decode( get_bloginfo( 'name' ), ENT_QUOTES ) );
	$message   = sprintf( __( "Howdy %s,\n\nYour account with %s needs to be verified before you can access your purchase history. <a href='%s'>Click here</a> to verify your account and get access to your purchases.", 'edd' ), $user_data->display_name, $from_name, $url );
	return $message;
}
add_filter( 'edd_user_verification_email_message', 'jp_customize_verification_email', 10, 2 );

Note: If this is your first time adding code snippets in WordPress, then please refer to our guide on how to properly add code snippets in WordPress, so you don’t accidentally break your site.

If you liked this code snippet, please consider checking out our other articles on the site like: 30 ways to make money online and how to add a portfolio to your WordPress site.

Comments   Leave a Reply

  1. Thanks for the snippet! Is there a way to modify this to disable the user verification email entirely?

Add a Comment

We're glad you have chosen to leave a comment. Please keep in mind that all comments are moderated according to our privacy policy, and all links are nofollow. Do NOT use keywords in the name field. Let's have a personal and meaningful conversation.

WordPress Launch Checklist

The Ultimate WordPress Launch Checklist

We've compiled all the essential checklist items for your next WordPress website launch into one handy ebook.
Yes, Send Me the Free eBook!