[wp-hackers] Issue with update-notify

Keith McDuffee gudlyf at realistek.com
Wed Jun 16 15:02:17 UTC 2004


I saw from the Plugin/API wiki page at http://wiki.wordpress.org/Plugin/API that the 'publish_post' hook is 
supposed to only kick in when a post is *first* published. However, with my update-notify plugin (that sends 
an email out to a list when the blog gets a new post), I've had to fiddle around trying to get it to not mail 
if an already published post gets edited. You can see from the latest version I have up at 
http://www.gudlyf.com/index.php?p=357 what I've tried. It only works if you don't first save the post to 
draft, then publish, so that's not going to work.

Is there another hook I'm supposed to use to only kick in on the initial publish of a post? Perhaps that wiki 
entry is described incorrectly?

Thanks.



More information about the hackers mailing list