Hi,

I have found a solution that I think works (have not got access to a Unix 
environment to confirm this) but I did not hard-code any window/unix specific 
paths.

Here's a snippet of code I used:

ServletContext scntxt = this.getServletContext();
String pathToFile = scntxt.getRealPath("/WEB-INF"); // or whatever relative to 
web app root eg /images

String imagePath = "file:" + pathToFile;

org.apache.fop.configuration.Configuration.put("baseDir",imagePath);

as you can see, all my images are in web_app_root/WEB-INF.

The corresponding xml data file looks like this:

<HTRelitiveRef HTRRKey="2" HTRRType="Picture" HTRRID="/centurion.jpg" 
HTRRLink="" HTRRVisible="F">centurion</HTRelitiveRef>

I hope this saves others the problem of finding the solution across many posts!

Thanks

Rakesh

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

Reply via email to