Future posting with dateCreated in Wordpress via XMLRPC in Ruby
I'm reaching the end of my tether trying to schedule a new post through Wordpress' XMLRPC interface from Ruby.
I am creating a new Time object and filling it with my date and time, I then call .xmlschema to get a datetime string in the correct format for Wordpress' XMLRPC interface.
Unfortunately, Wordpress treats this as a string, and I can't work out how to get the xmlrpc.php to treat it as an object; really can't get my head around it.
Calling the metaWeblog.newPost method, and sending:
{:title => 'Foo', :post_status => 'publish', :dateCreated => my_date.xmlsc开发者_开发问答hema}
to Wordpress.
Anyone been through this before?
Can you check what you are actually sending (the post data)? The date should be encapsulated in <dateTime.iso8601></dateTime.iso8601>
, not in <string></string>
. The WordPress Trac has a similar report.
精彩评论