[wp-trac] [WordPress Trac] #17850: XMLRPC API Clients can't edit underscore-prefixed custom fields

WordPress Trac wp-trac at lists.automattic.com
Mon Jun 20 02:58:51 UTC 2011


#17850: XMLRPC API Clients can't edit underscore-prefixed custom fields
--------------------------+-----------------------------
 Reporter:  redsweater    |      Owner:
     Type:  defect (bug)  |     Status:  new
 Priority:  normal        |  Milestone:  Awaiting Review
Component:  General       |    Version:  3.1.3
 Severity:  normal        |   Keywords:
--------------------------+-----------------------------
 Changes that were committed in r17994 changed the behavior of the XMLRPC
 API such that clients who attempt to create or modify custom field values
 that start with a "_" underscore, encounter a quiet failure for those
 values to stick.

 It seems at least somewhat common for 3rd party plugins and themes to use
 underscore-prefixed custom field values, in particular when they provide
 their own UI for setting those values, and don't want the values to show
 up in the custom fields UI of the WordPress admin panel.

 Because a remote client using the XMLRPC API doesn't cause the plugin's
 custom code or UI to appear, we need the ability to continue editing these
 fields via the API.

 A concrete example of this problem in action is the All In One SEO pack,
 which uses custom fields that have a prefix of _aiseop. My customers
 (MarsEdit) who have custom fields configured to edit these values are
 finding since 3.1.3 that the specified values simply "don't take" on the
 server.  I have traced this to the changes in r17994:

 http://core.trac.wordpress.org/changeset/17994

 Particularly to the new is_protected_meta which counts as protected any
 custom fields that begin with an underscore. Presumably this function ends
 up getting called on behalf of the API from the "edit_post" API call in
 post.php, but I haven't confirmed the exact call chain.

 It would be great if the XMLRPC API could continue having unfettered
 access to editing underscore-prefixed custom fields.

-- 
Ticket URL: <http://core.trac.wordpress.org/ticket/17850>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list