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

inline xslt and stylesheets

Subject: inline xslt and stylesheets
From: Venkat Raghavan Srinivasan <venkatrs@xxxxxxxxxxxxx>
Date: Thu, 21 Nov 2002 14:11:57 -0800
xml inline xslt
Hello All,

I am new to xslt design and development paradigm. I am trying out some
embedded xslt templates with inline styles. I have enclosed the snippet
below. 



<?xml version="1.0" ?>

<!DOCTYPE doc [
<!ELEMENT xsl:stylesheet ANY>
<!ATTLIST xsl:stylesheet id ID #REQUIRED>
]>

<?xml-stylesheet type="text/xsl" href="#style1"?>
<dummy>


<xsl:stylesheet   version="2.0" id="style1"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform">

<xsl:template match="xsl:stylesheet">
  <!-- ignore -->
</xsl:template>

<xsl:template match="/">
 <HTML>
 <HEAD>
   <TITLE>SVRaghav's</TITLE>
</HEAD>
 <STYLE>
	<![CDATA[
	.title{
	Font-Family : Arial, Helvetica, Verdana, Geneva, sans-serif;
	Color : #cccc66;
	Font-Size : 10px;
	Font-Style : normal;
	Margin-Left : 10;
	}
	]]>
</STYLE>

<BODY>
<xsl:apply-templates select="resume1" />
</BODY>
</HTML>
</xsl:template>

<xsl:template match="dummy1">
   <DIV CLASS="title">  <xsl:value-of  select="." /></DIV>
</xsl:template>

<xsl:template match="dummy1">
   <DIV CLASS="title">  <xsl:text> DUMMY2 </xsl:text></DIV>
</xsl:template>
</xsl:stylesheet>


<dummy1>DUMMY1</dummy1>

</dummy>



When you view the xml in the borwser (IE 5.x and above), I see that the
styles are applied to contents between the <xsl:text></xsl:text> tags
where
as the styles are not applied to contents between <xsl:value-of /> tags.

Could some one tell me why or what mistake I am making? Any pointers on the
same


thanks,
VS


 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


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.