Hi all,
I抳e stumbled across one problem, passing and displaying HTML markup via parameters.
Lets say I need to pass HTML string containing combo box to XSL and display it.
In JSP I set up parameters like this:
Hashtable params = new Hashtable();
params.put("param1", value);
strCombo = ?lt;select><option>Test Value</option></select>?
params.put("param2", strCombo);
in XSL I try to except and display it:
<?xml version="1.0" encoding="windows-1252"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xslutput method="html"/>
<xslaram name=" param1"></xslaram>
<xslaram name=" param2"></xslaram>
<xsl:template match="/">
<xsl:copy-of select=?param2?>
</xsl:template>
</xsl:stylesheet>
and instead of combo box I see literal string print out,
I know that I抦 on the rght path, because when I do this:
<?xml version="1.0" encoding="windows-1252"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xslutput method="html"/>
<xslaram name=" param1"></xslaram>
<xslaram name=" param2"><select><option>Test Value</option></select></xslaram>
<xsl:template match="/">
<xsl:copy-of select=?param2?>
</xsl:template>
</xsl:stylesheet>
It will display combo box as it should. I抦 definitely missing something, but what.
Please do not make suggestions like not passing HTML to XSL, it has to be like that, and that is that.
Thanks in advance
I抳e stumbled across one problem, passing and displaying HTML markup via parameters.
Lets say I need to pass HTML string containing combo box to XSL and display it.
In JSP I set up parameters like this:
Hashtable params = new Hashtable();
params.put("param1", value);
strCombo = ?lt;select><option>Test Value</option></select>?
params.put("param2", strCombo);
in XSL I try to except and display it:
<?xml version="1.0" encoding="windows-1252"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xslutput method="html"/>
<xslaram name=" param1"></xslaram>
<xslaram name=" param2"></xslaram>
<xsl:template match="/">
<xsl:copy-of select=?param2?>
</xsl:template>
</xsl:stylesheet>
and instead of combo box I see literal string print out,
I know that I抦 on the rght path, because when I do this:
<?xml version="1.0" encoding="windows-1252"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xslutput method="html"/>
<xslaram name=" param1"></xslaram>
<xslaram name=" param2"><select><option>Test Value</option></select></xslaram>
<xsl:template match="/">
<xsl:copy-of select=?param2?>
</xsl:template>
</xsl:stylesheet>
It will display combo box as it should. I抦 definitely missing something, but what.
Please do not make suggestions like not passing HTML to XSL, it has to be like that, and that is that.
Thanks in advance