velocity-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Nathan Bubna <nbu...@gmail.com>
Subject Re: problem displaying velocity content on webpage
Date Mon, 18 Jul 2005 22:47:59 GMT
you are using the wrong param-name for your toolbox.  it should be:

  <param-name>org.apache.velocity.toolbox</param-name>

On 7/18/05, Paul Goepfert <paul.goepfert@gmail.com> wrote:
> Nathan Bubna wrote:
> >need a bit more info than that...
> >
> >are you getting error messages in your logs at startup or elsewhere
> >that look pertinent?
> >
> According to my tomcat log there is no toolbox defined when I am pretty
> sure I have it defined
> >what do you mean by "does not render correctly"?
> >
> >
> The $link.setAction() method does not work, same with $text.get() so
> anything associated with these methods don't render.  I see the method
> calls rather then what the method is soppose to retreive from the
> properties file.
> >what are the tools in your toolbox.xml?
> >
> In my toolbox I have StrutsLinkTol, MessageTool, and FormTool
> 
> >showing us your toolbox.xml and web.xml might also be useful.
> >
> Here is my toolbox.xml
> 
> <?xml version="1.0" encoding="ISO-8859-1" ?>
> 
> <toolbox>
>     <tool>
>         <key>link</key>
>         <class>org.apache.velocity.tools.struts.StrutsLinkTool</class>
>     </tool>
>     <tool>
>         <key>text</key>
>         <class>org.apache.velocity.tools.struts.MessageTool</class>
>     </tool>
>     <tool>
>         <key>form</key>
>         <class>org.apache.velocity.tools.struts.FormTool</class>
>     </tool>
> </toolbox>
> 
> web.xml
> 
> <web-app version="2.4" xmlns="http://java.sun.com/xml/ns/j2ee"
>                        xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
> 
> xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee
> http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd">
> 
> 
> <servlet>
>         <servlet-name>velocity</servlet-name>
> 
> <servlet-class>org.apache.velocity.tools.view.servlet.VelocityViewServlet</servlet-class>
>         <init-param>
>             <param-name>org.velocity.toolbox</param-name>
>             <param-value>/WEB-INF/conf/toolbox.xml</param-value>
>         </init-param>
>         <load-on-startup>10</load-on-startup>
>     </servlet>
>     <servlet-mapping>
>         <servlet-name>velocity</servlet-name>
>         <url-pattern>*.vm</url-pattern>
>     </servlet-mapping>
> 
> I only included the velocity portion of my web.xml to save space.
> 
> -Paul
> >On 7/18/05, Paul Goepfert <paul.goepfert@gmail.com> wrote:
> >
> >>I built a velocity-struts application.  At the moment I can't get any of
> >>the classes found in the toolbox.xml file to be read.  I have the
> >>velocity tools jar and the velocity tools view jar in the lib dir. When
> >>I try and load the web app the velocity content does not render
> >>correctly.  I have checked my web.xml for typing mistakes as well as all
> >>other xml files.  I couldn't find any mistakes
> >>
> >>If anyone can help me please let me know.
> >>
> >>-Paul
> >>
> >>---------------------------------------------------------------------
> >>To unsubscribe, e-mail: velocity-user-unsubscribe@jakarta.apache.org
> >>For additional commands, e-mail: velocity-user-help@jakarta.apache.org
> >>
> >>
> >>
> >
> >---------------------------------------------------------------------
> >To unsubscribe, e-mail: velocity-user-unsubscribe@jakarta.apache.org
> >For additional commands, e-mail: velocity-user-help@jakarta.apache.org
> >
> >
> >
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: velocity-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: velocity-user-help@jakarta.apache.org
> 
>

---------------------------------------------------------------------
To unsubscribe, e-mail: velocity-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: velocity-user-help@jakarta.apache.org


Mime
View raw message