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

Re: xsl can't get graphic to load from xml file

Subject: Re: xsl can't get graphic to load from xml file
From: josh higgins <doopsterus@xxxxxxxxx>
Date: Thu, 7 Apr 2005 13:28:15 -0700 (PDT)
xmldocument load relative path
Ok, I don't think that I mentioned that I am new to
this xml and xsl thing.  So basically what you are
saying is that I cannot have a dynaminc path (one read
in from the xsl sheet) and place it in the url?  My
absolute path is already in the xml.  There is no
generation what-so-ever. So can this xml data be read
into local xsl:variable and then used in the url?  


I am using apache.xml.fop to generate my pdf off of my
xsl.


--- Eliot Kimber <ekimber@xxxxxxxxxxxxxxxxxxx> wrote:
> There is no simple single solution to this problem
> because it depends 
> entirely on the relative locations of the FO
> instance (if you are 
> generating an instance) and the graphic *at the time
> you render them*, 
> not at the time you generate the FO.
> 
> Therefore, for different processing environments, it
> might be most 
> appropriate to generate an absolute path and in
> others you have to 
> generate a relative path relative to some
> pre-defined location.
> 
> In addition, doing path processing is generally
> easier in a language 
> like Java than in XSLT (although you can do it in
> XSLT, of course). For 
> example, we have utility Java libraries that do
> things like compare two 
> paths and return the shortest relative path. We then
> expose these 
> through Saxon extension functions so that in the
> XSLT we can easily 
> generate relative paths to graphics given some base
> path (normally 
> passed in as a parameter to the XSLT process).
> 
> For one customer we have to provide an
> FO-generation-time option of 
> whether graphic paths are relative or absolute
> because different users 
> of the code have different business rules.
> 
> Finally, remember that relative paths will be
> relative to the location 
> of the FO instance, not the original XML document
> (unless you set the 
> xml:base attribute in the FO instance to be the
> location of the orignal 
> XML document), which can be a problem, especially if
> you generate the FO 
> instance and then move it somewhere else before
> rendering it.
> 
> This is all presuming that your graphics are not
> managed in some 
> URL-accessible content store that would allow you to
> specify 
> location-independent absolute URIs. In essence, all
> the W3C 
> specifications assume that this is the case, even
> though for most users 
> it is never the case.
> 
> Cheers,
> 
> Eliot
> -- 
> W. Eliot Kimber
> Professional Services
> Innodata Isogen
> 9390 Research Blvd, #410
> Austin, TX 78759
> (512) 372-8155
> 
> ekimber@xxxxxxxxxxxxxxxxxxx
> www.innodata-isogen.com
> 
> 


		
__________________________________ 
Yahoo! Messenger 
Show us what our next emoticon should look like. Join the fun. 
http://www.advision.webevents.yahoo.com/emoticontest

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.