how to retrieve value <blip:user>jetset</blip:user>in xml ?

  • adreny
  • Born
  • Born
  • adreny
  • Posts: 3

Post 3+ Months Ago

hi,
i got call a xml something like this.

Code: [ Select ]
<rss>
<item>
<guid isPermaLink="false">53A9C6E6-ECE8-11DD-8BD8-CA3B94C006BC</guid>
<link>http://blip.tv/file/1710703</link>
<title>and the oscar goes to...</title>
<blip:user>jetset</blip:user>
<blip:userid>33980</blip:userid>
<blip:safeusername>epicfu</blip:safeusername>

</item>
</rss>
  1. <rss>
  2. <item>
  3. <guid isPermaLink="false">53A9C6E6-ECE8-11DD-8BD8-CA3B94C006BC</guid>
  4. <link>http://blip.tv/file/1710703</link>
  5. <title>and the oscar goes to...</title>
  6. <blip:user>jetset</blip:user>
  7. <blip:userid>33980</blip:userid>
  8. <blip:safeusername>epicfu</blip:safeusername>
  9. </item>
  10. </rss>


i can retrieve all the childnote value, except the highlight childnote value.

below is my code:
Code: [ Select ]
function loadxml(success:Boolean){
    
    var nodes = xml.firstChild.childNodes[0].childNodes;
    var total = nodes.length;
    trace(total);
    
    if(success){
        for (var i:Number = 0; i<total; i++) {
            trace(i);trace(nodes[i].childNodes[3].localName);
                        // output -
        }
    }else{
        trace('fail!');
    }
}
  1. function loadxml(success:Boolean){
  2.     
  3.     var nodes = xml.firstChild.childNodes[0].childNodes;
  4.     var total = nodes.length;
  5.     trace(total);
  6.     
  7.     if(success){
  8.         for (var i:Number = 0; i<total; i++) {
  9.             trace(i);trace(nodes[i].childNodes[3].localName);
  10.                         // output -
  11.         }
  12.     }else{
  13.         trace('fail!');
  14.     }
  15. }


anyone here can help me ?
Moderator Remark: Added [code] tags
  • Anonymous
  • Bot
  • No Avatar
  • Posts: ?
  • Loc: Ozzuland
  • Status: Online

Post 3+ Months Ago

Post Information

  • Total Posts in this topic: 1 post
  • Users browsing this forum: No registered users and 10 guests
  • You cannot post new topics in this forum
  • You cannot reply to topics in this forum
  • You cannot edit your posts in this forum
  • You cannot delete your posts in this forum
  • You cannot post attachments in this forum
 
 

© 1998-2014. Ozzu® is a registered trademark of Unmelted, LLC.