You are viewing a plain text version of this content. The canonical link for it is here.
Posted to fop-users@xmlgraphics.apache.org by vivek gupta <gv...@yahoo.com> on 2004/08/18 19:29:41 UTC

image not included in my pdf under web-project

Hi,
    I am unsing XML and XSLT for creating my fo file
in my web project. But I am unable to include my
image. Please let me know how I need to write mey
path.

Right now I have code like this from my xsl file 

<fo:external-graphic
src="url(../../../web/image/A.jpg)" height="40pt"
width="60pt"/> 

my xsl file is  web-inf/classes/xsl/A.xsl

and image directory is 

/Context/web/image

Please help me

Thanks in advance
Vivek



__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 

---------------------------------------------------------------------
To unsubscribe, e-mail: fop-user-unsubscribe@xml.apache.org
For additional commands, e-mail: fop-user-help@xml.apache.org


Re: image not included in my pdf under web-project

Posted by "J.Pietschmann" <j3...@yahoo.de>.
vivek gupta wrote:
>     I am unsing XML and XSLT for creating my fo file
> in my web project. But I am unable to include my
> image. Please let me know how I need to write mey
> path.
> src="url(../../../web/image/A.jpg)"

A relative URL is usually resolved against the CWD of the servlet
container process, and not interpreted as relative to the webapp
root.
Either use an absolute file path, a proper relative path (which
depends on your servlet container and probably also on how it
is started), or use a full http URL and retrieve the image through
another servlet (protect the URL against non-local access if
necessary).

J.Pietschmann

---------------------------------------------------------------------
To unsubscribe, e-mail: fop-user-unsubscribe@xml.apache.org
For additional commands, e-mail: fop-user-help@xml.apache.org