Posted on Mar 9, 2010 by
Happy Cat
The WordPress upload_file method doesn't enocode the xml request properly. According to the following support post, it should be wrapped in a <base64> tag -- I looked at the XML, and the bits param is being wrapped in a <string>.
http://wordpress.org/support/topic/257938
I've tried using the method as is. The file uploads, but seems to be corrupted on the server...
Comment #1
Posted on Mar 10, 2010 by Happy CatNever mind. You just need to pass xmlrpclib.Binary(binary_data) to the bits param and xmlrpclib will take care of the encoding.
Status: New
Labels:
Type-Defect
Priority-Medium