On 15 Mar 2006 at 16:13, John Wiberg wrote: > I have a java class that runs fop. [...] but when I call the > class from a web application running under tomcat, it looks like it is using > the path from where I started tomcat. > > Any ideas? Yes, hope so :)
depending on what you want to do, maybe this helps: Edit <base>.</base> in %FOP_DIR%/conf/fop.xconf and save it to %CONF_FILE% wherever you want. As in http://xmlgraphics.apache.org/fop/0.91/embedding.html#config-external and http://xmlgraphics.apache.org/fop/0.91/embedding.html#config-internal described build your fop: import org.apache.avalon.framework.configuration.Configuration; import org.apache.avalon.framework.configuration.DefaultConfigurationBuilder; /*..*/ DefaultConfigurationBuilder cfgBuilder = new DefaultConfigurationBuilder(); Configuration cfg = cfgBuilder.buildFromFile(new File("%FULL_PATH_TO_CONF_FILE%")); userAgent.setUserConfig(cfg); Fop fop = new Fop(MimeConstants.MIME_PDF, userAgent); Hope this helped. Greetings, Joachim --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
