Subject: Truncated text string, relative to child node
From: "Michael Dango" <mdango@xxxxxxxxx>
Date: Tue, 1 Jul 2008 13:43:39 -0500
|
I have an XML file like this:
<a> lorem ipsum text ... lorem ipsum <b> dolor </b> lorem ipsum ...
lorem ipsum </a>
I want to create a string of the five words from <a> right before the <b>
tag, and a string of the five words immediately after <b>. All I can do
is create strings from the beginning or the end of the <a> tag, but
basically I want the text in the middle, relative to the child <b> node.
Thanks!
|