Hi Ronald,

I tried that and it works fine.  The problem is that the relative path where
my images are stored is not from the folder containing my fop.jar.  I
reference the dictionary in the same XSL as follows:
<xsl:variable name="lang"
select="document('/VincentSite/xml/Dictionary.xml')/Dictionary"/>
As you can see, the path used is a relative path.  "VincentSite" is an
alias, in Apache, for a folder in my HD.  The images are in a different
sub-folder within the same folder.  I know you can use images using a
relative path, but I am retrieving mine across a webserver (Apache), and
this seems to be where the problem lies.

Thanks for sticking with me on this.

Regards

Micheál

----- Original Message -----
From: Ronald Jaramillo <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Wednesday, July 18, 2001 2:04 PM
Subject: RE: external-graphic - problem using relative path


> try placing an image (say foo.gif ) on the same directory as the fop.jar .
> Then write a simple fo file:
>
> <?xml version="1.0" encoding="UTF-8"?>
> <fo:root xmlns:fo="http://www.w3.org/1999/XSL/Format";>
>     <fo:layout-master-set>
>         <fo:simple-page-master master-name="simple">
>             <fo:region-body margin-top="3cm"/>
>             <fo:region-before extent="1.5cm"/>
>         </fo:simple-page-master>
>     </fo:layout-master-set>
>
>     <fo:page-sequence master-name="simple">
>         <fo:flow flow-name="xsl-region-body">
>             <fo:block>
>                 <fo:external-graphic src="file:foo.gif"/>
>             </fo:block>
>         </fo:flow>
>     </fo:page-sequence>
> </fo:root>
>
> Place it in the same directory and test if from the command line.
> If this does not work, something is broken with the version of fop you are
> using.
> Most probably the path you are using should be relative to where the
fop.jar
> is placed ( this is what works for me, not necesary the best way to do
it )
>
> MVH
> Ronald
>
>
> > -----Original Message-----
> > From: Micheál Healy [mailto:[EMAIL PROTECTED]]
> > Sent: Wednesday, July 18, 2001 2:44 PM
> > To: [EMAIL PROTECTED]
> > Subject: Re: external-graphic - problem using relative path
> >
> >
> > Ronald,
> >
> > Thanks for the suggestion, but unfortuately, it hasn't
> > worked.  I still get
> > the following error - "Invalid Image URL - error on relative URL :
> > java.lang.NullPointerException".  I tried both <fo:external-graphic
> > src="file:VincentSite/img/chkbxgif-y.gif"/> and <fo:external-graphic
> > src="file:/VincentSite/img/chkbxgif-y.gif"/> with identical
> > results.  I
> > wonder if it's something to do with my configuration,
> > although, as I said, I
> > can read the dictionary using a relative path.
> >
> > Any ideas?
> >
> > Thanks,
> >
> > Micheál
> >
> >
> > ----- Original Message -----
> > From: Ronald Jaramillo <[EMAIL PROTECTED]>
> > To: <[EMAIL PROTECTED]>
> > Sent: Wednesday, July 18, 2001 12:38 PM
> > Subject: RE: external-graphic - problem using relative path
> >
> >
> > > try  <fo:external-graphic
> > src="file:VincentSite/img/chkbxgif-y.gif"/>
> > >
> > > mvh
> > > Ronald
> > >
> > > -----Original Message-----
> > > From: Micheál Healy [mailto:[EMAIL PROTECTED]]
> > > Sent: Wednesday, July 18, 2001 12:16 PM
> > > To: [EMAIL PROTECTED]
> > > Subject: external-graphic - problem using relative path
> > >
> > >
> > > Hi all,
> > >
> > > I posted a message regarding this problem a couple of weeks ago, but
> > > received no reply.
> > >
> > > I need to reference images ("external-graphic") in my xsl.
> > It seems to
> > work
> > > fine when I use the absolute path, but not when I use the
> > relative path.
> > > Please find attached my original message - it's a little
> > more detail and
> > > contains some sample XSL.
> > >
> > > Any help on this would be greatly appreciated.
> > >
> > > TIA,
> > >
> > > Micheál
> > >
> > > Micheál Healy
> > > Engitech Ltd.
> > > [EMAIL PROTECTED]
> > >
> > >
> > ---------------------------------------------------------------------
> > > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > > For additional commands, email: [EMAIL PROTECTED]
> >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, email: [EMAIL PROTECTED]
> >
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, email: [EMAIL PROTECTED]


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]

Reply via email to