I'm using the xalan JAXP transformer to transform a very simple xml file with a very simple xsl file. My goal is to create a snippet of HTML.

When I transform the document using XMLSpy I get html back. When I transform the same two files programmatically, my html is completely ignored and I get back text.

How frustrating is this, eh?!?!? Any ideas? --k

Here's the transform Java code:

public xmlTransform(String urlXML, String urlXSL)
throws TransformerException, TransformerConfigurationException, FileNotFoundException, IOException
{
TransformerFactory tFactory = TransformerFactory.newInstance();

Transformer transformer = tFactory.newTransformer(new StreamSource( urlXSL ));

// Use a ByteArrayOutputStream so that I can turn it into String
outStream = new ByteArrayOutputStream();
transformer.transform(new StreamSource( urlXML ), new StreamResult( outStream ));
}

Here's the xsl:
<?xml version='1.0'?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0">
<xslutput method="html" indent="no" />
<xslutput omit-xml-declaration="yes" />
<xsl:strip-space elements="*" />

<xsl:template match="commonopinion">
<xsl:apply-templates select="question" />
</xsl:template>

<xsl:template match="question">
<p>
Name: <xsl:value-of select="name"/><br/>
ID: <xsl:value-of select="id"/><br/>
Description: <xsl:value-of select="description"/><br/>
</p>
</xsl:template>

</xsl:stylesheet>