Your bundle and locale configuration is wrong: <tool> <key>text</key> <scope>application</scope> <class>org.apache.velocity.tools.generic.ResourceTool</class> <parameter name="bundles" value="com.mypackage.resources.moreResources"/> <parameter name="locale" value="en_US"/> </tool>
http://velocity.apache.org/tools/releases/1.4/javadoc/org/apache/velocity/tools/generic/ResourceTool.html On Wed, Mar 5, 2008 at 11:23 PM, Gil Vernik <[EMAIL PROTECTED]> wrote: > Hi, > I am trying to add a Resource tool , > I added the following line in the toolbox.xml > <tool> > <key>text</key> > <scope>application</scope> > <class>org.apache.velocity.tools.generic.ResourceTool</class> > <bundle>com.mypackage.resources.moreResources</bundle> > <locale>en_US</locale> > </tool> > > I created a file moreResources_en_US.properties in the package > com.mypackage.resources with only one line in it > nameTest=Name Test > > Now, when I use $text.nameTest in a velocity page I am getting an error > : > > org.springframework.web.util.NestedServletException: Request processing > failed; nested exception is java.util.MissingResourceException: Can't > find bundle for base name resources, locale en_US > > org.springframework.web.servlet.FrameworkServlet.processRequest(Framewor > kServlet.java:488) > > org.springframework.web.servlet.FrameworkServlet.doGet(FrameworkServlet. > java:431) > javax.servlet.http.HttpServlet.service(HttpServlet.java:690) > javax.servlet.http.HttpServlet.service(HttpServlet.java:803) > > I stuck with this for few days already and I cannot find any example how > to use it correct. What am doing wrong? > > Thanks, > Gil. > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
