0

xml response using javascript

hi guys i have a request.
when i make my requst in js using this code sentence

y.rest(url).get().response;

how can i control the format of the response? how can i control if it is an xml? and finally how can i convert it to an xml eventually?

thanks!!!

by
1 Reply
  • QUOTE (Samuele @ Apr 11 2010, 11:22 AM) <{POST_SNAPBACK}>
    hi guys i have a request.
    when i make my requst in js using this code sentence

    y.rest(url).get().response;

    how can i control the format of the response? how can i control if it is an xml? and finally how can i convert it to an xml eventually?

    thanks!!!


    YQL will automatically create e4x objects from the response if its XML or javascript objects if is JSON (it uses the response mimetype to determine what the data format is). If you need to explicitly tell YQL how to handle the response you need to specify the mime-type using "accept"

    See http://developer.yahoo.com/yql/guide/yql-j...pt-objects.html for an example

    Jonathan
    0

Recent Posts

in YQL