On my web site I have XMLs with my page contents (automatically generated from my DB) – which are displayed using XSLT. The problem is this: I’d like to have some formatting within some of the XML tags. For instance, if I have an XML containing an article in a
format like this:
<article>
<header>Cool article</header>
<author>Me!</author>
<content>
This is an article. It's <b>HUGE</b>, and here's a <a href="http://Www.foo.com">link</a>.
</content>
</article>
However, if I simply get the contents using this: <xsl:value-of select="content" /> all the HTML formatting is ignored/lost. I guess it’s mistaken for XML child nodes, and not actual data residing in the content node.
What’s the preferred way of achieving formatting like what described here?
Thanks in advance.
I think your problem is this:
make sure your output is of type html,