Getting text in mixed content

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • MarkoKlacar
    Recognized Expert Contributor
    • Aug 2007
    • 296

    #1

    Getting text in mixed content

    Picture this content:
    <top>
    this is the text I need to get my hand's on
    <nested>
    some text
    </nested>
    <nested>
    some text
    </nested>
    <nested>
    some text
    </nested>
    <nested>
    some text
    </nested>
    </top>

    Now, the text that comes before the <nested>-element is what I need to get my hand's on. The funny thing is that I've done this a 1000-times by accident but just can't figure out the proper way to do it.

    Cheers
  • MarkoKlacar
    Recognized Expert Contributor
    • Aug 2007
    • 296

    #2
    Just as I suspected it was as easy as 1,2,3.

    The solution, for those interested was:
    top/text()

    My apologies for wasting you time...

    Comment

    Working...