Hi,
That is not anymore an XML attribute as what you generate as output is
not XML. The simplest thing is to switch to text output method and
generate what you want:
<xsl:transform version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:output method="text"/>
<xsl:template match="/">
<![CDATA[<a href="<!--#echo var="grar.5.url" encoding="none"
-->">link</a>]]>
</xsl:template>
</xsl:transform>
Regards,
George
---------------------------------------------------------------------
George Cristian Bina - http://aboutxml.blogspot.com/
<oXygen/> XML Editor, Schema Editor and XSLT Editor/Debugger
http://www.oxygenxml.com
tom tom wrote:
I need to generate an apache .sssi file that contains the following kind
of code:
<a href="<!--#echo var="grar.5.url" encoding="none" -->">link</a>
To acheive this in XSLT 1 we generated the code as CDATA in a plain text
file:
<xsl:text disable-output-escaping="yes"><a href="</xsl:text>
<xsl:comment>#echo var='grar.5.url' encoding='none'</xsl:comment>
<xsl:text disable-output-escaping="yes">">link</a></xsl:text>
Can anyone advise on a cleaner way to do this using XSLT 2?
_________________________________________________________________
Txt a lot? Get Messenger FREE on your mobile.
https://livemessenger.mobile.uk.msn.com/
--~------------------------------------------------------------------
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--
--~------------------------------------------------------------------
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--