[wp-xmlrpc] Updating Custom Fields Using metaWeblog.editPost
Joseph Scott
joseph at josephscott.org
Tue Apr 7 23:10:15 GMT 2009
On Apr 7, 2009, at 2:09 PM, Daniel Jalkut wrote:
>> The reason for this because you can have duplicate keys, so the id
>> is required in order to uniquely identify a field. There's nothing
>> to stop you from having 25 custom fields on a post all with the
>> same key name.
>
> Do you have a sense for whether many (any?) plugins expect this kind
> of scenario? In providing a service to my customers, I'm expecting
> to allow them to configure named fields with the assumption that
> there will be a 1-1 relationship of names and fields. I wonder if
> I'm setting myself up for a customer backlash with this restriction.
>
> I'm thinking mostly of the obvious cases for custom fields like
> "mood", "music I'm listening to", etc. Seems like if it has a name,
> most customers will only expect for there to be one.
Unfortunately I don't have a feel for what people are actually doing
with custom fields out in the wild.
I agree that in many cases a simple one to one would work fine. I
could see situations where'd you not want that though, it makes it
easy to store one type of data multiple times. Here's a made up
example, what if you wanted to save the GPS coordinates of your
location every time you edited a post? Would be simple enough to have
a custom field key called "gps_edit_location" with the value storing
all the bits you needed. A theme could then ask for all of the
"gps_edit_location" custom fields for each post and display them
accordingly.
--
Joseph Scott
joseph at josephscott.org
http://josephscott.org/
More information about the wp-xmlrpc
mailing list