I am using wp_mail() function to sending email. I have one static string "Hello Admin". My clients wants convert this string to language string. So it possible to convert static string to language string while sending email.
What I have done so far, please refer my below code.
$current_user = wp_get_current_user(); $admin_email = get_option('admin_email'); $subject = get_bloginfo('name').' - Publish Details'; $message = _("Hello Admin,",'text-domain'); $message .= "$current_user->user_login has published details. Details are as following.\r\n"; wp_mail($admin_email,$subject,$message,$headers)
John has published details. Details are as following.
I am not getting language string in email. Any help would be appreciate.