[wp-hackers] Proper action to hook to save custom fields with comments?

Nathaniel Taintor goldenapplesdesign at gmail.com
Mon Sep 27 01:34:46 UTC 2010

Hi all,

I'm getting stuck trying to add custom fields to a comment form and
wondering if anyone else can point me in the right direction. I have a
couple additional fields I need to add to the comment form.

Since these fields need to show up for all users, whether logged in or not,
I think I'm correct in understanding that I can't use the
'comment_form_default_fields' filter. As far as I can tell, these fields are
only displayed for users who are not logged in.

So instead I modified the 'comment_field' body in 'comment_form_defaults' to
include my additional input fields. I haven't found an action hook or filter
on saving comments that I can hook into to access these fields, though. I've
tested 'edit_comment' and 'comment_save_pre', but I can't seem to access the
POST data for my custom fields at either one of these. What am I dong wrong?

Thanksn in advance,

Nathaniel Taintor, Designer/Developer
*Golden Apples Design*


@GoldenApples | 503.877.2880
goldenapplesdesign at gmail.com

More information about the wp-hackers mailing list