This is the mail archive of the
xsl-list@mulberrytech.com
mailing list .
Re: refrencing unparsed entities within an attribute
- To: xsl-list at mulberrytech dot com
- Subject: Re: refrencing unparsed entities within an attribute
- From: "Rick Geimer" <Rick dot Geimer at nsc dot com>
- Date: Wed, 14 Jun 2000 16:58:51 -0700
- References: <20000614221252.92548.qmail@hotmail.com>
- Reply-To: xsl-list at mulberrytech dot com
Yasser,
The entity declaration you posted unfortunately is not valid XML. You
could use something like the following though:
<?xml version="1.0"?>
<!DOCTYPE tag [
<!ELEMENT tag EMPTY >
<!ATTLIST tag attr ENTITY #IMPLIED >
<!NOTATION TEXT SYSTEM "" >
<!ENTITY e1 SYSTEM "e1.txt" NDATA TEXT>
]>
<tag attr="e1"/>
Then have "ValOfE1" in the e1.txt file. I suppose you could also have
"ValOfE1" as the system identifier and retrieve it with
unparsed-entity-uri(), but that would be poor practice I suppose, since
you probably do not intend "ValOfE1" to be a real URI.
Also, be aware that if you cannot recreate unparsed entity declarations
in your output with XSLT, since it doesn't support writing to the
declaration subset.
Rick Geimer
National Semiconductor
rick.geimer@nsc.com
Yasser El-Zein wrote:
>
> In the XML, if I have an unparsed entity value:
> <!ENTITY e1 "ValOfE1" NDATA TEXT>
> can I refrence it within the value of an attribute?
> something like: <tag attr="&e1;"/>
> Knowing that this value can be referenced within the value of an attribute
> in the XSL using: {unparsed-entity-uri('e1')}.
>
> ________________________________________________________________________
> Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com
>
> XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list