trying to find the comment hook I need for wordpress?
I'm writing a wordpress plugin that will execute a certain function when a user submits a comment. The only issue is I'm using the hook "comment_post" which works but i开发者_运维百科f that comment gets stopped by akismet I'm still logging that comment but now my numbers are off from what's on the actual site. Is there a comment_approved type hook I should be using instead?
this is something I was looking at not too long ago, Only thing is the admin has to approve/edit the comment before the function would run..
using the wordpress admin hook:
wp_set_comment_status()
This function is run after changing the status of the comment by the admin.., this looks for the status from 4 options
status ("delete", "approve", "spam", "hold").
You can check for the status approve? do your caculation from there?
精彩评论