[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Re: Output in XML / HTML, double tags and CDATA in sc

Subject: Re: Output in XML / HTML, double tags and CDATA in script.
From: Andrew Ferk <andrewferk@xxxxxxxxx>
Date: Tue, 17 Feb 2009 11:59:32 -0600
Re:  Output in XML / HTML
On Tue, Feb 17, 2009 at 11:20 AM, sOLOWXEW aNDREJ
<solovev@xxxxxxxxxxxxxx> wrote:
> Is there any way to solve this problem?  I need "<br/>" style tags in my
> result html and working script.

The xsl code below should work for you.

<?xml version="1.0"?>
<xsl:stylesheet
version="1.0"
xmlns="http://www.w3.org/1999/xhtml"
xmlns:php="http://php.net/xsl"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform">


<xsl:output method="xml" encoding="utf-8"
 doctype-system="http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"
 doctype-public="-//W3C//DTD XHTML 1.0 Transitional//EN" indent="yes" />

<xsl:template match="/">
 <html>
 <body>
 	<xsl:text disable-output-escaping="yes">
  &lt;script language="Javascript"&gt;
	//&lt;![CDATA[
    if(1 == 1 &amp; 2 == 2)
     alert(1);
	//]]&gt;
  &lt;/script&gt;
	</xsl:text>
  <br/>
  <img src="test.jpg"/>
 </body>
 </html>
</xsl:template>
</xsl:stylesheet>

--
Andrew Ferk

Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.