xmlgraphics-fop-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Esse <e...@widenarrow.se>
Subject Relative paths when running FOP as servlet (Tomcat)
Date Wed, 25 Aug 2010 11:25:11 GMT

Hi fopusers!

Specs:
Latest fop (1.0)
Latest tomcat (7.x)

I’m using the fop servlet example in tomcat, with a config file. 

Right now, FOpServlet is modified like this:

protected void configureFopFactory() {
        try {
                fopFactory.setUserConfig(new File("/conf/fop.xconf"));
        } catch (SAXException e) {
                System.out.println(e);
        } catch (IOException e) {
                System.out.println(e);
        }
    }

However, the path for the config file in the above example is
C:\conf\fop.xconf . 

How to make config file path relative(in jar/war/tomcat folder?

Really anywhere would do except a hard path, like [JAVA_HOME]/conf/fop.xconf
or something like that.


Please help :)


-- 
View this message in context: http://old.nabble.com/Relative-paths-when-running-FOP-as-servlet-%28Tomcat%29-tp29531194p29531194.html
Sent from the FOP - Users mailing list archive at Nabble.com.


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


Mime
View raw message