I was having trouble getting Velocity‘s date tool to work with Spring MVC. I followed the instructions, most copied verbatim from what was most likely one ancient source. Those instructions said that to enable Velocity’s date formatting tool, DateTool, I needed to configure the VelocityViewResolver like this (WRONG): <bean id="viewResolver"> class="org.springframework.web.servlet.view.velocity.VelocityViewResolver"></bean> <br /><property name="numberToolAttribute"><value>numbertool</value></property> <br [...]
Using Velocity date tool with Spring MVC
June 17th, 2008 No Comments
Tags: Java · Spring MVC · Veloicty
Spring MVC binding problem
May 31st, 2008 No Comments
Spring MVC has a very peculiar approach to handling dates from form submissions. Gone are what I feel is the ‘standard’ approach to forms, via select drop-downs, and in comes the open input text field. That may be valid especially if you are using a JavaScript-based date selector element. Fine. The issue is that those [...]
Tags: binding · Spring MVC
Setting up Spring MVC welcome page without rewrites or redirection
May 23rd, 2008 No Comments
So you have a Spring MVC web application and want to make sure that when the user enters a URL such as http://www.myawesomedomain.com he/she will see the home page of your application. How do you get Spring MVC’s RequestDispatcher servlet, which acts as the traffic cop and then some for your web application, to act [...]
Tags: default page · index · redirect · root · Spring MVC · web.xml · welcome page