From: Steve B. <ste...@ya...> - 2006-10-11 15:14:10
|
Hi, I'm having a problem parsing some XML in PERL with SOAP::LITE and was wondering if anyone could help me out. I'm trying to get access to the each of the networkAdmin nodes (see below) while parsing the individual networks. The way I've been trying to do this heretofore is: for my $t ($som->valueof('//networks/network')) { print $t->attr->{ID} . "\n"; #now print each of the user admins #doesn't work###f or my $tt($som->valueof('networkAdmin')) { #doesn't work### print $tt->attr{status} . "\n"; } Any help you could give so that I can access the networkAdmin nodes while parsing the individual network nodes would be appreciated. XML below: XML below: <networks> <network ID="1600012" name="node2"> <metadata> <location>ireland</location> <date_established>2006-06-28</date_established> </metadata> <networkAdmin UID="1" name="X" techCert="C1" status="1"/> <networkAdmin UID="2" name="XX" techCert="D1" status="1"/> </network> <network ID="1611400" name="nodeX"> <metadata> <location>utah</location> <date_established>1954-11-24</date_established> </metadata> <networkAdmin UID="1" name="AB" techCert="A1" status="1"/> <networkAdmin UID="2" name="AC" techCert="E1" status="1"/> <networkAdmin UID="3" name="AC" techCert="E1" status="1"/> </network> Thanks in advance! --------------------------------- Get your email and more, right on the new Yahoo.com |