Ticket #7446 (closed enhancement: fixed)

Opened 4 years ago

Last modified 19 months ago

XMLRPC Comments API

Reported by: ryan Owned by: anonymous
Priority: normal Milestone: 2.7
Component: XML-RPC Version:
Severity: normal Keywords: comments xmlrpc blessed
Cc: josephscott, redsweater

Description

Add API to XMLPRC for retrieving and managing comments.

Attachments

7446.diff Download (4.7 KB) - added by ryan 4 years ago.
Incomplete and untested preview
7446.2.diff Download (8.2 KB) - added by ryan 4 years ago.
Drop separate method for setting comment status. Flesh out editComment.
7446.3.diff Download (12.8 KB) - added by ryan 4 years ago.
Add get_comments(). Register methods. Deprecate some old stuff.
7446.4.diff Download (13.4 KB) - added by ryan 4 years ago.
All methods tested except newComment. It needs some more work.
7446.5.diff Download (13.7 KB) - added by ryan 4 years ago.
Allow fetching comments for a particular post
7446.6.diff Download (14.2 KB) - added by ryan 4 years ago.
Working newComment
7446.7.diff Download (15.5 KB) - added by ryan 4 years ago.
Handle anonymous comments
7446.8.diff Download (15.7 KB) - added by ryan 4 years ago.
Add offset and number support to getComments
7446.9.diff Download (15.7 KB) - added by ryan 4 years ago.
Couple small corrections

Change History

comment:1   ryan4 years ago

  • Keywords blessed added
  • Cc josephscott added
  • Type changed from defect to enhancement
  • Component changed from General to XML-RPC

There's been some discussion about this on the wp-xmlrpc list:  http://comox.textdrive.com/pipermail/wp-xmlrpc/

ryan4 years ago

Incomplete and untested preview

ryan4 years ago

Drop separate method for setting comment status. Flesh out editComment.

ryan4 years ago

Add get_comments(). Register methods. Deprecate some old stuff.

ryan4 years ago

All methods tested except newComment. It needs some more work.

ryan4 years ago

Allow fetching comments for a particular post

comment:3   ryan4 years ago

getComments() accepts optional status and post_id. A separate getPostComments() has been suggested. It'd probably just be an alias to getComments() with different argument passing if we added it.

newComment() needs a little more work. All other methods have had basic testing and are hopefully complete.

  • Cc redsweater added

ryan4 years ago

Working newComment

comment:5   ryan4 years ago

In 7446.6 all methods are completed and tested. I left support for unregistered commenting out of newComments for now.

ryan4 years ago

Handle anonymous comments

ryan4 years ago

Add offset and number support to getComments

ryan4 years ago

Couple small corrections

comment:7   ryan4 years ago

(In [8543]) XML-RPC comments API. see #7446

When editing a comment in moderation,  http://trac.wordpress.org/browser/trunk/wp-includes/comment.php?rev=8543#L863 is causing the comment to be be approved with any changes to the Approval Status.

comment:9   ryan3 years ago

  • Status changed from new to closed
  • Resolution set to fixed

(In [8622]) comment_approved can be zero, so check with isset instead of empty. fixes #7446

(In [8698]) Typo fix. Props josephscott. see #7446

Note: See TracTickets for help on using tickets.