Hi,

I've got a very simple JSP which parses an xml document containing some html. The problem is that when I try and output the html part, all the tags within it are removed. Example code and result below (I just want the <body> section in my output).

I suppose this is expected behaviour, but is there anything I can do to output all the tags.

Thanks in advance,

Digby

XML file:

<?xml version="1.0" encoding="UTF-8"?>
<doc>
    <head>
        <title>Introduction</title>
        <section>section</section>
        <channel>testing/test</channel>
    </head>
    <body>
        <h1>Heading</h1>
        <p>Lorem ipsum dolor sit amet.</p>
        <p>Donec sed enim.</p>
    </body>
</doc>

JSP:
<c:import var="page" url="/pages/index.xml"/>
<x:parse var="xml" xml="${page}"/>
<x:set var="body" select="$xml//body"/>
<x:out select="$body"/>

result:
Heading Lorem ipsum dolor sit amet. Donec sed enim. [with no tags]


--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to