|
[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Re: refrencing unparsed entities within an attribute
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@xxxxxxx
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
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|

Cart








