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

Re: parsed entites

Subject: Re: parsed entites
From: "Alexandra Morgan" <lexalex@xxxxxxxxxxxxx>
Date: Thu, 18 Nov 1999 13:48:04 -0800
alexandra morgan
I can't see what I'm doing wrong here. I'm using LotusXSL. Internal entities work, but not external entities. Here are the first few lines of my stylesheet:

<?xml version='1.0'?>
<!DOCTYPE xsl:stylesheet [
<!ENTITY header SYSTEM "http://localhost\header.xml">
<!ENTITY yo "Yo!">
]>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/XSL/Transform/1.0">

And here are the complete contents of header.xml:

<?xml version='1.0' encoding='UTF-8'?>
	<B>This is a nifty report. <HR/></B>

I can put the string &yo; in my templates and it copies the text Yo! to the output as expected. But where I put &header; the XSL processor reports an error.

TIA,
Alex

 
--

On Wed, 17 Nov 1999 16:46:14   G. Ken Holman wrote:
>At 99/11/17 13:20 -0800, Alexandra Morgan wrote:
>>As I understand it, entities have to be declared inside the DOCTYPE. But 
>>my stylesheets don't have a DTD. Can I have a DOCTYPE without having a DTD?
>
>It isn't a problem to have a DOCTYPE without a DTD.
>
>When I work with the text output method, I usually create a &nl; entity to 
>emit line feeds in my output as follows:
>
><?xml version="1.0"?>
><!DOCTYPE xsl:stylesheet [
><!ENTITY nl "
">
>]>
><xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
>                 version="1.0">
>
><xsl:output method="text"/>
>
><xsl:template match="/">
>   <xsl:text>&nl;</xsl:text>
></xsl:template>
>
></xsl:stylesheet>
>
>
>You can also have partial DTDs ... a common XSLT processing requirement for 
>well-formed documents is to recognize which attribute of elements is of 
>type ID (because there is nothing special conferred on attributes that are 
>*named* ID).
>
>To communicate this information regarding the source file to the 
>stylesheet, the following can be added to the source:
>
><!DOCTYPE custsummary [
><!ATTLIST cust custNbr ID #REQUIRED>
>]>
><custsummary>
>......
>
>I hope this helps.
>
>............ Ken
>
>
>--
>G. Ken Holman                    mailto:gkholman@xxxxxxxxxxxxxxxxxxxx
>Crane Softwrights Ltd.             http://www.CraneSoftwrights.com/s/
>Box 266, Kars, Ontario CANADA K0A-2E0   +1(613)489-0999   (Fax:-0995)
>Web site: XSL/XML/DSSSL/SGML services, training, libraries, products.
>Practical Transformation Using XSLT and XPath      ISBN 1-894049-02-0
>Next instructor-led training:              1999-12-05/06, 1999-12-07,
>-                            2000-02-27/28, 2000-05-11/12, 2000-05-15
>
>
> XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
>


***********************************
chickclick.com
http://www.chickclick.com
girl sites that don't fake it.
http://www.chickmail.com
sign up for your free email.
***********************************


 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.