> Just fixed it in CVS thanks to Rafal's suggestion.  You can 
> now optionally
> leave WebMacros property file out of your classpath and 
> specifically set
> its location in the TurbineResources file. 

All right Dave, we are moving in the right direction!

This should eventualy weed out one of the most frequent problems 
with setting up Turbine+WebMacro. One more problem remains here
though. The location of WebMacro.properties we specify in 
TrubineResources.properties must be either absolute in server's 
filesystem, or relative to anything the servlet container choses
to be it's current directory. This is definetely not the best
solution we could get.
The thing I really wish to add here is checking if 
ServletContext.getRealPath() works and if it does (which usually
means that we are running under Tomcat) translate relative paths
to be relative to our web application root.
Having getRealPath() at hand would enable us to do one more cool
thing - to add a RelativeTemplatePath to WebMacro.properties file
and make it override TemplatePath if present, and getRealPath()
is working.
To be able to do this, we need to have an instance of ServletConfig
avaliable inside TurbineWebMacroService.init(). This was supposed
to be handled by Kevin Burton's service intialization code. There
was a discussion of that at the end of May, but it sort of died
out. I'll try to contact Kevin, and in case he is not available
I'll implement this stuff myself.

Rafal



------------------------------------------------------------
To subscribe:        [EMAIL PROTECTED]
To unsubscribe:      [EMAIL PROTECTED]
Search: <http://www.mail-archive.com/turbine%40list.working-dogs.com/>
Problems?:           [EMAIL PROTECTED]

Reply via email to