Titanium Community Questions & Answer Archive

We felt that 6+ years of knowledge should not die so this is the Titanium Community Questions & Answer Archive

Parsing XML is broken after update with SDK 1.1

Hi There,

This morning I have updated with titnium SDK 1.1 but after updating I was not able to parse rss it is completely broken.

Are there anu changes made on parsing XML because it was working in all previous versions

Thanks!

— asked March 23rd 2010 by Skinkers Developer
0 Comments

9 Answers

  • I again confirm. A slightly different issue: TiDOMNodeList.item(int index) errors out. Try pasting this at line 113 in examples/xml_dom.js in Kitchen Sink 1.1.x:

    112:  elements = nodes.item(0).childNodes;
    113:  result = result && (elements!=null && elements.length==3);
    #new code
    Titanium.API.debug(elements);
    Titanium.API.debug(typeof elements.item);
    Titanium.API.debug(elements.item(0).nodeName);
    

    Outputs:

    [DEBUG] [object TiDOMNodeList]
    [DEBUG] function
    [DEBUG] Was set was set to 1
    2010-03-24 12:03:01.649 KitchenSink[63649:854f] *** -[TiDOMElementProxy kind]: unrecognized selector sent to instance 0x5375080
    [ERROR] Script Error = *** -[TiDOMElementProxy kind]: unrecognized selector sent to instance 0x5375080 at xml_dom.js (line 116).
    
    — answered March 24th 2010 by Harry Brundage
    permalink
    0 Comments
  • it also seems as though with 1.1.2 android is not parsing CDATA wrappers correctly.

    — answered April 2nd 2010 by Jim Carter III
    permalink
    0 Comments
  • I can confirm this issue. My application which parses feeds now displays the feed <title> rather than the <item>'s <title>. Worked fine in 1.0 but not 1.1.0.

    — answered March 23rd 2010 by A G
    permalink
    0 Comments
  • Yea, my app's xml parsing is toast under 1.1 iPhone BUT it still works ok on the Android.

    — answered March 23rd 2010 by rob stevens
    permalink
    0 Comments
  • Ditto. All broken for me as well. I can retrieve attributes of nodes OK. If I am looping through a node list and using firstChild,lastChild for referencing nodes in the loop it's fine, but trying to use getElementsByTagName on any node I'm looking on (say if I am looking for a set of child nodes in th current node), just returns the first node every time.

    — answered March 24th 2010 by Brandon Kenna
    permalink
    0 Comments
  • We're working on a fix. We're likely to do a 1.1.1 maintenance push to resolve these and other critical issues found ASAP.

    — answered March 24th 2010 by Jeff Haynie
    permalink
    0 Comments
  • This is still broken in 1.2.0 for the iPhone.

    — answered April 16th 2010 by Kenton Hankins
    permalink
    0 Comments
  • This is still broken in 1.2.0 for the iPhone.

    — answered April 16th 2010 by Kenton Hankins
    permalink
    0 Comments
The ownership of individual contributions to this community generated content is retained by the authors of their contributions.
All trademarks remain the property of the respective owner.