xsl-list
[Top] [All Lists]

[xsl] RE: using entities

2011-08-17 08:25:58
I have figured this out using unparsed-entity-uri(). Feel kinda foolish now. 

Thanks

-----Original Message-----
From: Furst, Tom [mailto:tom(_dot_)furst(_at_)rcmt(_dot_)com] 
Sent: Wednesday, August 17, 2011 7:50 AM
To: xsl-list(_at_)lists(_dot_)mulberrytech(_dot_)com
Subject: [xsl] using entities

I am trying to figure out how I can make use of enitity declarations when using 
XSL/XSL-FO to generate PDFs. In the XML I am using each file has a declaration 
similar to this:

<!ENTITY ICN-LJ200-A-J344405-A-24210-00002-A-001-01 SYSTEM 
"ICN-LJ200-A-J344405-A-24210-00002-A-001-01.cgm" NDATA cgm>

In my XML where there is a graphic I have the following markup:
<figure id="F0001">
<title>Radio Altimeter Antenna</title>
<graphic id="gra001" 
infoEntityIdent="ICN-LJ200-A-J344405-A-24210-00002-A-001-01"></graphic>
</figure>

The attribute infoEntityIdent matches the entity name at the beginning of the 
file. To get the graphic in the PDF this in the XSL:

<xsl:for-each select="./graphic">
            <xsl:variable name="graphFile" select="./@infoEntityIdent"/>
            <xsl:variable name="gFileDir" select="concat($graphFile,'.cgm')"/>
.
      <fo:external-graphic src="url('{$gFileDir}')" display-align="center" 
content-height="21cm"/>
</xsl:for-each>

I want to find out if it's possible to use the entity declaration to get the 
filename, as it may not always be a .cgm (or any other format for that matter) 
graphic. 

Thanks for the help,

Tom


--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--


--~------------------------------------------------------------------
XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
To unsubscribe, go to: http://lists.mulberrytech.com/xsl-list/
or e-mail: <mailto:xsl-list-unsubscribe(_at_)lists(_dot_)mulberrytech(_dot_)com>
--~--

<Prev in Thread] Current Thread [Next in Thread>