Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- add_action('woocommerce_created_customer', 'admin_email_on_registration', 10 , 1);
- function admin_email_on_registration($customer_id, $new_customer_data, $password_generated) {
- $headers = 'From: My Name <myname@example.com>' . "\r\n";
- $content = "Dane użytkownika: " . print_r($new_customer_data, true) . PHP_EOL;
- $content .= "Wygenerowane hasło: " . $password_generated;
- wp_mail('test@example.org', 'Rejestracja nowego użytkownika', $content, $headers);
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement