Announcement Announcement Module

Spring Modules forum decommissioned in favor of Spring Extensions

As the Spring Modules project has been replaced by the Spring Extensions ( project, this forum has been decommissioned in favour of Spring Extensions one at:

Please see the Spring Extensions home page for a complete list of current projects in Java, .NET and ActionScript. You can also propose one if you want.

Costin Leau
SpringSource - Spring Training, Consulting, and Support - "From the Source"
See more
See less
Valang client-side / Freemarker demands a body! Page Title Module
Move Remove Collapse
Conversation Detail Module
  • Filter
  • Time
  • Show
Clear All
new posts

  • Valang client-side / Freemarker demands a body!

    I have valang working, including client-side validation in freemarker. I'm using the new Spring 2.0 freemarker/taglibs integration.

    The problem is, the validate tag expects a body, and if it doesn't get a body, it chucks a parse error.

    I reference the valang js tags like so:

    HTML Code:
    <#assign valang=JspTaglibs[""]>
    if I do this:

    HTML Code:
    <@valang.validate commandName="command" />
    I get this:
    freemarker.template.TemplateModelException: javax.servlet.jsp.JspException: Could not parse valang
    at freemarker.ext.jsp.TagTransformModel$TagWriter.aft erBody(
    caused by this:

    org.springmodules.validation.valang.parser.ParseEx ception: Encountered "<EOF>" at line 1, column 0.
    Was expecting:
    "{" ...
    If I do this:
    HTML Code:
    		<@valang.validate commandName="command">
    		{ stupid : ? has text : 'this is stupid' }
    it works fine (except I have to define a javascript-only rule that I do not want)

    I did not have this problem in JSP.

    Help? Anyone?