Subject: Inserting un-encoded text From: "Tom Gilbert" <tomg@xxxxxxx> Date: Wed, 16 Jun 1999 14:28:39 -0500 |
This is probably
simple but how do I get un-encoded HTML output
from a script function in a style sheet? This example returns encoded characters Here's the condensed and simplified version of what I tried: <xsl:script> <![CDATA[ function bold(e) { if ( e.previousSibling.text == "ip address" ) return "<B>" + e.text + "</B>"; else return e.text; return; } ]]> </xsl:script> <xsl:template match="id_value"> <xsl:eval>bold(this)</xsl:eval> </xsl:template> Typical xml: ...<id><id_type>ea address</id_type><id_value>123</id_value></id> <id><id_type>ip address</id_type><id_value>1.2.3.4</id_value></id>... In this case I'd like the ip address to appear bold. The function returns "<B>....." so that the B tag is ignored by the browser. Tom
Gilbert |
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
RE: Generating non-HTML in a HTML d, Kay Michael | Thread | XSL wysiwyg tool, Eric E. Cohen |
RE: Can solve the N-queens - but ca, Wilson, James.W | Date | RE: Searchable XML, Mark Birbeck |
Month |