I have a stylesheet embedded in my html page like:
<xml id="xslFix">
<xsl:styleshe et xmlns:xsl="http ://www.w3.org/1999/XSL/Transform"
version="1.0">
<xsl:output method="html"/>
<xsl:param name="statusfie ld"></xsl:param>
......<snip>... .
</xml>
I want to modify the:
<xsl:param name="statusfie ld"></xsl:param> node and add a text node
there so it looks like:
<xsl:param name="statusfie ld">stuff in here</xsl:param>
<script language="JavaS cript">
var sf = new ActiveXObject(" MSXML2.FreeThre adedDOMDocument .4.0");
sf.load(xslFix) ;
var omap = sf.documentElem ent.getElements ByTagName('xsl: param');
for ( var i=0; i<omap.length; i++ )
{
if ( omap.item(i).ge tAttribute("nam e") == "statusfiel d" )
{
myText=omap.ite m(i).createText Node('stuff..') ;
omap.item(i).ap pendChild(myTex t);
}
}
</script>
But this does not work. I get an error message saying something about
this object not avaailable in this manner.
Any help is appreciated.
Mike
<xml id="xslFix">
<xsl:styleshe et xmlns:xsl="http ://www.w3.org/1999/XSL/Transform"
version="1.0">
<xsl:output method="html"/>
<xsl:param name="statusfie ld"></xsl:param>
......<snip>... .
</xml>
I want to modify the:
<xsl:param name="statusfie ld"></xsl:param> node and add a text node
there so it looks like:
<xsl:param name="statusfie ld">stuff in here</xsl:param>
<script language="JavaS cript">
var sf = new ActiveXObject(" MSXML2.FreeThre adedDOMDocument .4.0");
sf.load(xslFix) ;
var omap = sf.documentElem ent.getElements ByTagName('xsl: param');
for ( var i=0; i<omap.length; i++ )
{
if ( omap.item(i).ge tAttribute("nam e") == "statusfiel d" )
{
myText=omap.ite m(i).createText Node('stuff..') ;
omap.item(i).ap pendChild(myTex t);
}
}
</script>
But this does not work. I get an error message saying something about
this object not avaailable in this manner.
Any help is appreciated.
Mike
Comment