Pregunta

I am trying to use RightJS in a new project. What I am trying to do is:

  • Having a XHR request to the server
  • Retrieve a XML back
  • Parse the XML and update the page accordingly

The code works for Firefox and Safari but when I try to load it with IE I got a:

Object doesn't support this property or method error

The code is simplified as follow:

1: Xhr.load('get_xml.php', {
2:  onSuccess: function(r) {        
3:    var xml_obj = $(r.repsonseXML);
4:    var children = xml_obj.find('my_node');
5:  }
6: });

on line 3 IE gives an error. Is it related to RightJS unable to handle Microsoft XML obj?

Is that the proper way to handle XML in RightJS?

¿Fue útil?

Solución

Got feedback from another channel that JSON is the recommended data protocol in RightJS.

So in IE if one wants to use XML she has to fallback to native XML element parsing methods.

Licenciado bajo: CC-BY-SA con atribución
No afiliado a StackOverflow
scroll top