This week's book giveaways are in the Refactoring and Agile forums.
We're giving away four copies each of Re-engineering Legacy Software and Docker in Action and have the authors on-line!
See this thread and this one for details.
Win a copy of Re-engineering Legacy Software this week in the Refactoring forum
or Docker in Action in the Agile forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Struts Layout - date keyPattern exception

 
Alessandro Ilardo
Ranch Hand
Posts: 218
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi there,
I'm using Struts Layout library, on Struts 1.2.9 - JBoss 4.0.5

I'm having some trouble on a JSP page with the layout ate tag. I need to date format as 25/12/2008, which should match the following pattern dd/MM/yyyy. Unfortunatly this is not accepted by the tag attribute, which returns an exception.

12:26:25,543 ERROR [InsertTag] ServletException in '/WEB-INF/jsp/shift/form-datePicker.jsp': Illegal pattern character 'e'
org.apache.jasper.JasperException: Exception in JSP: /WEB-INF/jsp/shift/form-datePicker.jsp:20

17: <layout:skin/>
18: <table>
19: <% // <layout ate value="gg/mm/aaaa" calendarTooltip="Seleziona la data" patternKey="${constants['it.federfarma.modena.struts.Constants.UTIL_DATE_PATTERN']}" property="${constants['it.federfarma.modena.struts.Constants.SHIFT_WEEK']}" mode="E,E,E" /> %>
20: <layout ate value="gg/mm/aaaa" patternKey="dd/MM/yyyy" calendarTooltip="Seleziona la data" property="week" mode="E,E,E" />
21: </table>
22: <br />
23: <span class="error"><html:errors property="${constants['it.federfarma.modena.struts.Constants.SHIFT_WEEK']}"/></span>


Stacktrace:

If a completely remove the attribute keyPattern, I have not esceptions, but the date remains as 25/12/08

Thanks in advance
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic