I am using WordPress directory theme. I want to send an email to the author of the post whenever he publishes a new post. Currently, email is just sent to the administrator only. I didn't find any code utilizing wp_admin function.


2 Answers 2


The easiest way is to tie into the WordPress action publish_post. Here is a link to the codex with a basic example:


Note: If you are looking to do this for a Custom Post Type, you'll need to add an action for publish_custom_post_type.


Although I haven't tested it, a quick search revealed this (new) plugin which claims to do what you want:


Publish post notification is plugin which will send automatic email when the post is published and approved by WordPress blog. admin have to go to setting and set email template thats it all other things are managed by this plugin.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.