Check if the email is not going to spam or junk folder. Sometimes, emails from automated systems can be classified as spam by email providers.
Make sure that the email address ‘[email protected]’ is correct and working.
Verify that the four product IDs in the $targeted_ids array are correct and match the IDs of the products you want to trigger the email.
Make sure that the code is executing by adding some debug statements like “echo ‘Code is executing’;” at the start of the function to see if it’s being executed.
Check if the email sending functionality is working on the website by trying to send a test email using a plugin like WP Mail SMTP.
Finally, you can also try using a different email address for the recipient to check if the issue is specific to the email address ‘[email protected]’.
Related Posts:
- Woocommerce HTML email option unavailable
- PHP 8, AJAX mail form to function.php doesn’t work
- Get user custom field value on function.php
- Use of antispambot with $curauth->email
- Changing default WPMU emails to be send thorugh Campaign Monitor Transactional emails
- How can disable wordpress emails notifications?
- Notify admin (by email) if post added with specific tag
- Dynamic Email Handler with ‘header (“Location: …’
- How can I send an email using PHP?
- List of all theme customizer control types?
- Modify previous and next text from pagination links
- Shortcode putting html such as
- Calling a method from functions.php on a click of a button
- How to redirect users to custom lostpassword page?
- How to change featured content to a different tag in WordPress Twenty Fourteen?
- Can I write ‘RewriteCond’ using ‘functions.php’?
- How do I create comment-reply-button using element not
- WordPress menu deletes when trying to add a hook
- Overriding a theme redux file in child theme
- Validate a users email address when using gmail to register
- Get widget settings function?
- How to check If Oembed is empty or not
- Making Quote Plugin more efficient
- Adding tawk.to code just before body tag on functions.php file
- allow subscribers to see private posts without plug in
- Can I prevent the user from adding more than two levels deep of terms inside of a taxonomy metabox?
- Show css depending on activity type in BuddyPress activity-loop [closed]
- remove wp floating submenu in wp dashboard
- ACF: how do I get the fields and its values of a specific group?
- Fatal error: Uncaught Error: Call to undefined function test()
- Get page that displays all children of taxonomy parent
- Return a numerical function value in Customizer controls
- How can I get the values of my WordPress $wpdb query in Jquery?
- Show when user is online/offline in real time on user_profile.php
- Adding a widget function into the php theme file
- My new button is in the wrong place
- theme_root returning a truncated URI
- Call to undefined method – Download Monitor
- Call to undefined function get_userdata() in plugin
- Echo string and function?
- How to change menu labels
- Adding wrapper elements in the_date() like in the_title()?
- How to obtain the current website URL in my theme?
- Notify users only on post publish
- Plugin Generate Unexpected output during activation
- Remove Custom Divs from AMP pages
- Read array in php?
- Is it possible to display a DIV to not logged in users and then change it for users who are logged in?
- PHP code for displaying WordPress posts in a static page not working
- Remove extract from function
- Undefined offset: 3 in custom function
- How to add data to a custom field at the wp_users table?
- How can I use custom menus with a Bootstrap WordPress theme?
- How to make a cookie be on the whole site instead of being on a specific page/
- Child Theme’s Read More Text
- call a string/function from database
- Get date function not working
- How to remove/hide collapse menu for user/subscriber?
- How to implement __() function in my theme’s php file?
- Can/should we delete wordpress cron jobs with no action?
- How a HTML form can trigger a PHP function?
- Allow a user or role to view drafts and previews, but not other admin privileges?
- Get current user id in function php
- Proper way to remove html code on child theme
- Trying to add Custom Post Type to this functions.php command
- Apply function.php filter only if url not has /amp/
- Preventing direct access to a page in WordPress
- How to use data URL in WordPress?
- Flushing the slug base has no effect and does not change
- Display a custom name when the user has no name settle in his account
- Multiple cron jobs vs daily cron job doing multiple things? Which one yields better performance and scalability?
- Discount in the specific product title using keyword ( Woocoommerce )
- Modify post image in full size
- How to link all featured images to custom url in single.php for only non-logged-in users?
- JQuery modal not loading video on popup, only displaying it after multiple reopenings
- Menu to the right of screen on desktop using Bootstrap 4
- custom post type column countdown
- Creating wordpress user registration form
- Add missing alt tag to featured images for “storefront” theme
- Notice: Undefined index: post_title error
- Unable to pass arguments to function used in add_action
- Load admin bar without wp_head or wp_footer [duplicate]
- Allow user to select location and then set cookie for location in WordPress
- My query keeps looping infinitely ! how to stop it?
- Highlight Single Page Ancestor
- Registration form not registering First and Last name
- Removing get_template_part in child theme
- Merge / Combine two php functions for Previous and Next Link with Thumbnail
- str_replace not responding in functions.php [closed]
- How to get the rating value of each comment
- Adding php within a return statement [closed]
- Adding multiple emails to a
- Error in php code
- How can I prevent wordpress from sending emails
- How can I fix my pagination?
- How to send push notification in android using php? [closed]
- Replace the image of a product with its video in the shop page
- How call WordPress shortcode inside function file
- strict custom php script on specific product category [closed]
- Custom plugin doesn’t show in admin menu – when code added, displays an empty page