Re: [xsl] a quick question re:   html entity

Subject: Re: [xsl] a quick question re:   html entity
From: Terence <tk.lists@xxxxxxxxxxx>
Date: Fri, 07 Feb 2003 16:46:44 +1100
Marco Guazzone wrote:

my advice is to use a numerical entity; so for "&nbsp;" you could just
An alternative, if you prefer to write it in a symbolic way you can:
1) add <!ENTITY > declaration in the DTD of your sheet
2) you can create a named template like this:
  <xsl:template name="ent:nbsp">
3) AVOID THIS: use xsl:text with 'disable-output-escaping="yes"' attribute
  and do this: <xsl:text
  but this way is NOT THE RIGHT ONE.
  THINK TWICE BEFORE USING disable-output-escaping :))
Hope this helps!

The solution and the alternatives you provided were most helpful to say the least. Thanks :)

At the moment, I'm trying to output

<form method="post" id="filter" action="/sops/sk.php?op=listing&NOCACHE=1&DEBUG=xml" />

but I always get &amp; due to output escaping.

<form method="post" id="filter" action="/sops/sk.php?op=listing&amp;NOCACHE=1&amp;DEBUG=xml" />

It looks like I have no choice but to disable output escaping in this particular instance.

For the above example, I used the following code to produce it...
<form method="post" id="filter">
* *<xsl:attribute name="action"><![CDATA[/sops/sk.php?op=listing&NOCACHE=1&DEBUG=xml]]></xsl:attribute>

is there any way to achieve what I want without turning off output escaping?

XSL-List info and archive:

Current Thread