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

RE: Including inc files in xsl

Subject: RE: Including inc files in xsl
From: "SANWAL, ABHISHEK (HP-Houston)" <abhishek.sanwal@xxxxxx>
Date: Tue, 27 Jan 2004 17:08:57 -0600
including .inc files in html
The following is how I have embedded non-xml data into the XSL files
such that they have them in the result output.

e.g. Embedding the data in styles.css into the result

Hope that helps.

****************************

<!-- This DOCTYPE declaration ENTITY "stylescss" serves the following
purposes:
- allows the CSS file to be independent of the XSLs before compilation
- allows the CSS styles to be embedded into the output HTML on the fly
(instead of being linked)
-->

<!DOCTYPE xsl:stylesheet [
<!ENTITY stylescss SYSTEM "styles.css">
]>
<xsl:stylesheet version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform">

<xsl:template match="Document">
<html>
<head>

<xsl:comment>Embed the Cascading Style Sheet (CSS) data from
styles.css</xsl:comment>
<!-- Embed the Cascading Style Sheet (CSS) data from styles.css -->

<style type="text/css">
<xsl:comment>
&stylescss;
</xsl:comment>
</style>

</head>
<body bgcolor="#FFFFFF">
<!-- Apply templates and g

 

____________________________________________________________

Abhishek Sanwal
HP - Houston Campus

-----Original Message-----
From: owner-xsl-list@xxxxxxxxxxxxxxxxxxxxxx
[mailto:owner-xsl-list@xxxxxxxxxxxxxxxxxxxxxx] On Behalf Of David
Carlisle
Sent: Tuesday, January 27, 2004 3:33 PM
To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx
Subject: Re:  Including inc files in xsl



> I tried both the ways 
> 
> <!--#include virtual="myinclude.inc"-->

This is just a comment in the stylesheet so has no effect on the result.
 
>  and
>  
>  <xsl:comment>#include
>  virtual="myinclude.inc"</xsl:comment>
> 
> it did not work for me.
> 

what do you mean by didn't work?
It should create the comment
<!--#include virtual="myinclude.inc"-->
in the result tree, which was your stated requirement.
It will not of course include the file, that would be the job of your
server side inclusion system (ASP or whatever you are\using)

David

-- 
http://www.dcarlisle.demon.co.uk/matthew

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


 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.