Is it possible to use JavaScript with XML and XSL?
I tried the following but it does not work.. anything missing?
test.xml file:
--------------
<?xml version="1.0" encoding="ISO8859-1" ?>
<?xml-stylesheet type="text/xsl" href="test.xsl"?>
<REPORT>
<FOOTER>
<FIELD id="errors">
<KEY>Error Code</KEY>
<VALUE>2000145</VALUE>
</FIELD>
<FIELD id="configuration">
<KEY>DEBUG</KEY>
<VALUE>TRUE</VALUE>
</FIELD>
</FOOTER>
</REPORT>
test.xsl file:
--------------
<?xml version='1.0'?>
<xsl:stylesheet version='1.0'
xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:template match="/">
<HTML>
<BODY bgcolor="palegoldenrod">
<SCRIPT LANGUAGE="javascript">
<!--
function seeFooter_onclick()
{
footer1.style.display = "none"
}
//-->
</SCRIPT>
<INPUT id="seeFooter" type="checkbox" LANGUAGE="javascript"
onclick="seeFooter_onclick()">FOOTER</INPUT>
<TABLE id="footer1" bgcolor="#d1d2d2" border="1" width="100%">
<xsl:for-each select="REPORT/FOOTER/FIELD">
<TR>
<TD width="40%"><xsl:value-of select="KEY"/></TD>
<TD><xsl:value-of select="VALUE"/></TD>
</TR>
</xsl:for-each>
</TABLE>
</BODY>
</HTML>
</xsl:template>
</xsl:stylesheet>
The basic requirement is on the click of checkbox the <TABLE> should
disappear. But when i click the checkbox, browser generates an error.
I might also be posting this in the wrong newsgroup, so the pointer to
the right also would help
Regards
Fareeda