Courtesy of Andy we have some new comment creation functions.
- wp_insert_comment() – Add a new comment to the DB
- wp_update_comment() – Update an existing comment in the DB
- wp_filter_comment() – Filter comment data
- wp_allow_comment() – Perform various spam checks on a comment
This is in addition to the already existing wp_new_comment(). The extra functions allow importers to skip spam checks and comment notifications when importing comments. The new functions are already being put to use in the Blogger importer.
5 thoughts on “New Comment Functions”
Do any of these new comment functions allow for nested comments in the new and improved WP?
No. None of these functions are used in templates. These are backend functions useful to plugin and importer developers.
Ryan, I did make sure wp_insert_comment() handles the comment_parent field. As soon as a theme or plugin supplies that data in the form post, it should work. 🙂
I knew you guys had your thinkin’ caps on!