Uploaded image for project: 'Struts 2'
  1. Struts 2
  2. WW-3908

FreeMarker textfield tag doesn't allow the new HTML5 required attribute

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 2.3.7
    • 2.3.12
    • None
    • None
    • Windows 7 + JDK1.6.0_27 + The new Struts2 2.3.6 + FreeMarker 2.3.19

    • Important

    Description

      It is impossible to use the new HTML5 required attribute with the textfield tag currently available in FreeMarker. Other HTML5 attributes seem to work as expected.

      => For example, I want to use the new required attribute in order to have the following very simple HTML code :

      <input type="text" required="required" id="test-X">
      

      => I have tried to use the following code in a classic FTL file :

      test.ftl
      <@s.textfield required="required" id="test-1"/>
      <@s.textfield required="true" id="test-2"/>
      <@s.textfield required=required id="test-3"/>
      <@s.textfield required=true id="test-4"/>
      

      The HTML result is always :

      <input type="text" id="test-X">
      

      Attachments

        Issue Links

          Activity

            People

              lukaszlenart Lukasz Lenart
              vsct Loic VSCT
              Votes:
              1 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: