Or you can set the base directory for FOP to be the root of your Servlet 
Context by calling:

    Configuration.put("baseDir",getServletContext().getRealPath("/"));

I use this code in the Servlet.init() of my controller since it only needs to 
be called once.
  (*Chris*)

Original Message -----------------------
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: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


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

Reply via email to