views:

138

answers:

1

Hi there,

I'm using Wordpress's XML-RPC framework in my project. Now I have a situation where in the XML response there is a tag named which contains user data and by the time the response has been parsed and returned as some array format, that tag and it's value are gone. I have traced this down to NSXMLParser's parse method. Anyone know what's going on, why does the parser eat the id element?

response is: <?xml version="1.0" encoding="UTF-8"><methodResponse><params><param><value><array><data><value><struct><member><name>id</name><value>2009-10-01Demo</value></member><member><name>distance</name><value><double>3.0</double></value></member><member><name>fuel</name><value><double>5.199999809265137</double></value></member><member><name>cost</name><value><double>8.199999809265137</double></value></member><member><name>begin</name><value><dateTime.iso8601>20091011T12:30:11</dateTime.iso8601></value></member></struct></value></data></array></value></param></params></methodResponse>2009-11-16 16:20:26.943 ProjectName[2102:207]`

decoded value: ( { begin = 2009-10-11 12:30:11 -0700; cost = 8.2; distance = 3; fuel = 5.2; } )

I realize that id is always a sensitive word but still...

A: 

Turns out this is the problem:

http://ws.apache.org/xmlrpc/faq.html#string%5Fformat

Leonard