You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Michael Delamere <ho...@michael-delamere.de> on 2002/09/11 13:31:17 UTC

[Velocity] Problems with multiple subapps and message resources....

Hi all,

I was contemplating on wether to send this to struts or to velocity and
opted for this one because there is virtually no traffic at velocity-user
today.  I would really appreciate it if people could share their experiences
on this matter....

And yes, I´ve searched google, the struts-user archives and the
velocity-user archives and read the user-guide :-).

The poblem is as follows.

I´m using stuts1.1b2 with multiple subapps and the velocity template engine.
Now I have defined a resource file for each subapp and would like to output
the fields in my velocity templates.  Unfortunately this isn´t happening and
I´m getting the following messages:

############# Message resource has loaded?
4037 [main] INFO util.PropertyMessageResources  - Initializing,
config='com.morelogs.ims.resources.shop.ShopResources', returnNull=true

############# Velocity error I think
[ERROR] Message resources are not available.
 Velocity   [warn] org.apache.velocity.runtime.exception.ReferenceException:
reference : template = /shop/../WEB-INF/shop/templates/ShowProduct.vm [line
1,column 5] : $msg.get("label.showcart.pageheader") is not a valid
reference.

I had a look at the example from the velocity-struts-tools but that seems to
be based on struts1.0.1 without multiple application support.  I assume that
it may have something to do with that because I´m virtually doing it exactly
as it was done there and it won´t work.

Hase anyone had more experience with this which they are willing to share?

Thanks,

Michael




--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>