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

XHTML validations for s:hidden in form

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • 2.3.15.3
    • 2.3.20
    • Core Actions
    • Plattform independent

    Description

      Hello!

      I first posted this in user user@struts.apache.org, please see:
      https://mail-archives.apache.org/mod_mbox/struts-user/201403.mbox/%3CDUB129-W3328CF1DD22C328A3F2480B1880@phx.gbl%3E

      It looks like this might be a bug since the form do not pass validation at:
      http://validator.w3.org/check

      The problem is that hidden tags in the form is within the table, but do not get any tr and td tags.

      The struts-users helped me to this work around:

      I put a new file "hidden.ftl" in my resources-folder (I use maven with eclipse):
      resources/template/xhtml/hidden.ftl

      The content in hidden.ftl is:

      <tr style="display:none;">
      	<td>
      		<#include "/${parameters.templateDir}/simple/hidden.ftl" />
      	</td>
      </tr>
      

      Then it validates fine!

      Best regards
      Fredrik
      .

      Attachments

        Issue Links

          Activity

            People

              lukaszlenart Lukasz Lenart
              fredand44 Fredrik Andersson
              Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

                  Estimated:
                  Original Estimate - 2h
                  2h
                  Remaining:
                  Remaining Estimate - 2h
                  2h
                  Logged:
                  Time Spent - Not Specified
                  Not Specified