Reject Comments Based on Author Email

Here’s a suggestion for a filter: /** * Filters a comment’s approval status before it is set. * * @since 2.1.0 * @since 4.9.0 Returning a WP_Error value from the filter will shortcircuit comment insertion and * allow skipping further processing. * * @param bool|string|WP_Error $approved The approval status. Accepts 1, 0, ‘spam’ or WP_Error. … Read more

How to change WordPress email notification sender?

As of version 4.9 there is a dubious “feature” that prevents you from changing the site email without a confirmation email going out, and the admin confirming his own change. Those filters, as you’ve discovered, won’t work. For instance, from now on, if you’re using WordPress for an IOT device or on localhost, it’s impossible … Read more

How to pass external variables to the wp_new_user_notification_email filter?

I believe the problem is you’re using get_stylesheet_directory_uri() function in an attempt to include a file. This function returns a URL when what you want to do when you need to include a file is provide a path. You could be using instead is get_stylesheet_directory() Here’s what the output would look like: // – https://yourwebsite.com/wp-content/themes/my-theme/ … Read more

How can I check if a user’s email exists in the database

There’s the email_exists() function that could help you with checking if an email already exists among users. It’s e.g. used by register_new_user(). More here: https://developer.wordpress.org/reference/functions/email_exists/ https://developer.wordpress.org/reference/functions/register_new_user/

Tag subscription option in wordpress. How?

If you’re willing to use an outside provider, you can add the tag feed to Feedburner. First get the tag feed: http://www.example.com/?tag=tagname&feed=rss2 Then to to feedburner.com and create a feed, then enable “Email Subscriptions” (under the “Publicize” tab). I’ve done this, and it works well.