Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Xml childvalue tag output problem.
#1
Subtag is not output, it is output as follows.
What should I do if I want to be included in the google childvalue?

output
child=a; childvalue=abcde
child=c; childvalue=aabbcc
child=d; childvalue=?
child=b_0; childvalue=bbaacc

Function xmltest
Code:
Copy      Help
str new
str xml =
;<?xml version="1.0" encoding="utf-8" ?>
;<resources>
,;<string name="a">abcde</string>
,;<string name="c">aabbcc</string>
,;<string name="d">
,,;<a href="http://google.com">google</a>
,;</string>
,;<string name="b_0">bbaacc</string>
;</resources>

IXml x._create
x.FromString(xml)
ARRAY(IXmlNode) a
x.Path("resources" a)

int i
for i 0 a.len
,IXmlNode n=a[i].FirstChild
,rep
,,if(!n) break
,,out "child=%s; childvalue=%s" n.AttributeValue("name") n.Value()
,,n=n.Next


Messages In This Thread

Forum Jump:


Users browsing this thread: 1 Guest(s)