This week's giveaway is in the Spring forum.
We're giving away four copies of Learn Spring Security (video course) and have Eugen Paraschiv on-line!
See this thread for details.
Win a copy of Learn Spring Security (video course) this week in the Spring forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Retreiving the CDATA section in XML with DOM Parser

 
sn omen
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Sample XML



Main.java



Parser.java



With the above code I'm able to extract 'title', 'link' and 'pubDate'.
How can I extract 'href' value and the Text (IMF chief Christine Lagarde arrives at a Paris......) within the 'description' tag?
 
g tsuji
Ranch Hand
Posts: 656
3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
How can I extract 'href' value and the Text (IMF chief Christine Lagarde arrives at a Paris......) within the 'description' tag?

This is one way how you can do.
 
sn omen
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks.It worked fine.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic