Hi @dm007, are other emails sent without issues on your site?
Thread Starter
dm007
(@dm007)
Yes. In fact I also get other emails from the plugin, such as:
1) A new user subscribed to your giveaway
2) You have enrolled to the Giveaway. Good Luck!
It’s just the Winner notification email that does not get sent.
Hi @dm007, that might be something with the user’s email.
I’ll check it out and let you know.
Thread Starter
dm007
(@dm007)
Another odd thing is that the ‘Reselect Winner’ does not work. No matter how many times I press the button the winning email address does not change.
I use several caching plugins on my website and webhost to speed up WordPress. Would they cause any issue with your plugin?
Hi @dm007,
if your giveaway “Prize Info > Type” is set to “Most Entries win” and there is only one subscriber with most entries, that subscriber will always get chosen.
Hi @dm007,
I have tested everything and it works fine.
This plugin sets “Yes” for notified winners if the function wp_mail returns true. If it’s false it might be due to something related to email sending.
Do you have any plugins that modify the email setup?
Thread Starter
dm007
(@dm007)
Yes I do. I use Sparkpost to send emails.
I use their WordPress plugin which disables the internal PHPMAIL setup and routes all the emails through SparkPost.
https://ww.wp.xz.cn/plugins/sparkpost/
Hi @dm007,
I’ll check it out but I would guess the winners are notified but the wp_mail function returns false due to how their plugin is setup.
Since I can’t really know if they received the email, I rely on the return value of wp_mail.
Thread Starter
dm007
(@dm007)
I tried using a few of my email addresses to test and I didn’t get any emails. So it likely is having issues because wp_mail is not behaving as it expects due to the Sparkpost email plugin.
Hi @dm007,
Ok, thank you for letting me know on that. I’ll have to create an account and test it out to see what is the issue here.