Opened 16 years ago
Closed 16 years ago
#8343 closed defect (bug) (fixed)
Comment Form Submission: need action hook
Reported by: | tonebari | Owned by: | |
---|---|---|---|
Milestone: | 2.8 | Priority: | normal |
Severity: | normal | Version: | |
Component: | Comments | Keywords: | has-patch commit |
Focuses: | Cc: |
Description
I wrote a little AJAX plugin to challenge-response the browser on comment form load. It provides CAPTCHA if no JavaScript. Problem is I had to hack wp-comments-post to use wp_die() if validation doesn't happen. It would be awesome to have an action hook right after nocache_headers().
Attachments (1)
Change History (6)
#2
@
16 years ago
- Milestone changed from Future Release to 2.8
itching to close as invalid. wp-load.php ends with the init hook. you can use it to conditionally call nocache_headers() and die if your check is failed.
attaching a patch nonetheless.
please close as invalid/wontfix if this doesn't make it into 2.8.
#3
@
16 years ago
- Component changed from General to Comments
- Keywords has-patch commit added
- Owner anonymous deleted
#4
@
16 years ago
You can already use the pre_process_comment hook in wp_new_comment to achieve what you want.
However, I can see the benefit of another hook here for earlier work.
I am going to add an action to the if/then/else that appears just after so it only fires if WordPress would have accepted the comment anyway.
New action is called 'pre_comment_on_post'
Punting due to feature freeze. Reconsider with next release.