質問

I am calling a data service from a jaggery js app using http://jaggeryjs.org/apidocs/ws.jag . The data comes back in XML with members .responseText and .responseE4X. Is there an easy way to convert this response to JSON? Is there a parameter I can set to have this respond with JSON? This is being run in the server side, so I do not have access to window(), which most XML to JSON converters use.

Thanks!

役に立ちましたか?

解決

I did this by using the post method: http://jaggeryjs.org/apidocs/post.jag

It is worth noting that there is a bug in this as well. I had to set the content type header as "content-type" and not "Content-Type".

ライセンス: CC-BY-SA帰属
所属していません StackOverflow
scroll top