[fpc-pascal] getting XML element's value using dom.pp unit
Bisma Jayadi
bisma at brawijaya.ac.id
Thu Dec 8 05:36:51 CET 2005
> Perhaps it contains whitespace? It's possible that the XML parser
> creates more than one text node.
Hmmm... it sounds weird if a whitespace would create (automatically) another
text node 'cause it would change the XML structures.
> Do you have an excerpt of your XML file? This would be very helpful.
Here's the complete XML file I was trying to read...
<?xml version="1.0" encoding="UTF-8"?>
<BAIS_XML Version='1.0'>
<RESPOND ID="BAIS">
<RESPOND_TIME>2005.01.20 12:26:58</RESPOND_TIME>
</RESPOND>
<REQUEST ID="SI1">
<REQEUST_TIME>2005.01.20 12:26:58</REQUEST_TIME>
</REQUEST>
<CONTENT ID="L1">
<USER ID="simba">
<GROUP ID="1">Operator bank</GROUP>
<NAME>Bisma Jayadi</NAME>
<ALIAS>simba</ALIAS>
<PASSPORT>FB0woDvKVE4AFQW29a9E</PASSPORT>
</USER>
<LOCATION ID="1">
<CODE>UPPTI.1</CODE>
<NAME>Komputer Bisma</NAME>
</LOCATION>
</CONTENT>
</BAIS_XML>
It was an XML-RPC reply actually, 'cause I'm making an XML-RPC client. I'm able
to get all the attributes's names and values, the elements's names, but not the
elements's value. :(
I'm using Lazarus 0.9.10 (with FPC v.2.0.1) on winXP SP2 and Linux FC4 (using
KDE) on a same machine using Intel P4 2.2 GHz and 256 MB memory. My code behaves
the same on both environments.
I'm now inspecting the dom.pp and xmlread.pp source to know what's really going
on. But it'd take some times to understand the code, mean while I need help from
this mailing-list.
Thanks.
-Bee-
has Bee.ography at
http://beeography.blogsome.com
More information about the fpc-pascal
mailing list