[Home] [By Thread] [By Date] [Recent Entries]

  • To: <xml-dev@l...>
  • Subject: use SAX to get "tree" under XML node
  • From: "Will Johnson" <will.johnson@a...>
  • Date: Wed, 14 Nov 2001 14:32:44 -0500

i'm using the Apache SAX parser and i need to get the XML tree underneath a specific node.
 
for example in the following xml file...
 
<fields>   
    <field1>value 1</field1>
    <field2><style value="red"/><values>value 2</values></field2>
</fields>
 
i want to be able to get the trigger on the element field2 and somehow get back the string
 
<style value="red"/><value1>value1</value1><value2>value 2</value2></values>
 
if i use a regular sax processor to get all the characters i end up getting only the text which in this case would be "value 1 value 2"
 
any way around this?
 
thanks
 
 
 

Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member