[
http://www.stripesframework.org/jira/browse/STS-751?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12054#action_12054
]
Timothy Stone commented on STS-751:
-----------------------------------
I now have a complete patch... maybe just in time for the closing of v1.5.4.
See attached "stripes-html-config.tgz" for diffs.
After some sputtering and rehashing, I settled on the idea that the output
desired should be a deploy time configuration.
I wrestled with making it an Application configuration (context-param) or a
Stripes Filter configuration (init-param), and settled in making the solution
as "Stripey" as possible with a Stripes Filter setting, following the
RuntimeConfiguration documentation.
The following shows the application configuration set by the deployer as an
init-param to the Stripes Filter to "HTML" (the default remains XHTML and does
not require configuration):
<filter>
<filter-name>
StripesFilter
</filter-name>
...
<init-param>
<param-name>
Stripes.HtmlMode
</param-name>
<param-value>
HTML
</param-value>
</init-param>
</filter>
This configuration is called internally in the FormTag, HtmlTagSupport and
InputOptionsCollectionTag (or every where Stripes closed empty elements with "
/>"), e.g.,
"html".equalsIgnoreCase(StripesFilter.getConfiguration().getHtmlMode())
Backward compatibility is maintained and the default is "as it exists today."
The deployer, on advice from Front End Engineers, can set the Stripes Filter to
use the HTML 4 compatible tag syntax (also compatible with HTML 5).
Hope this meets everyone's expectations of default nature and configuration
while remaining "Stripey."
> Add support ala Struts to generate HTML or XHTML compliant close tags
> ---------------------------------------------------------------------
>
> Key: STS-751
> URL: http://www.stripesframework.org/jira/browse/STS-751
> Project: Stripes
> Issue Type: Improvement
> Components: Tag Library
> Affects Versions: Release 1.5
> Environment: No specific OS required; no specific Java version
> required; etc...
> Reporter: Nikolaos
> Priority: Minor
> Attachments: stripes-html4-input-0.1.jar, stripes-xhtml-patch.tar.gz,
> stripes-xhtml-patches.tar.gz
>
>
> HTML and XHTML documents have some key differences.
> For example - if we consider the <input> tag:
> - In HTML, the <input> tag has no end tag e.g. <input name="website.url"
> type="text" size="30">
> - In XHTML, the <input> tag must be properly closed, like this <input />
> e.g. <input name="website.url" type="text" size="30" />
> Stripes 1.5.x however does not have a mechanism to discern whether or not to
> properly close tags or not and as such takes the safer approach which is to
> explicitly close tags as it results in valid XHTML and is not an error for
> HTML but results in a warning when validating HTML documents. Although the
> latter is not a critical issue it does result in needless or unnecessary
> complaints when validating and as such is an annoyance albeit minor.
> Struts since 1.x has solved this issue quite easily by allowing the inclusion
> of the xhtml="true" attribute to mark that closure is required (false
> indicates no closure). In this manner authors of XHTML and HTML documents
> are equally satisfied in not having any errors or extraneous warnings.
> Timothy Stone had reported this issue and classified it as a bug here:
> http://www.stripesframework.org/jira/browse/STS-556?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=11931#action_11931
> The issue was rightly closed as "Not a bug" as most of the discussion was
> based on a non-w3c validator which yielded results that considered the
> validation unsuccessful which is not the case with the w3c validator (not to
> mention that it is irrelevant whether or not XHTML is considered dead or we
> should align to HTML 5 - etc...).
> As such this issue report is a re-statement of the above closed issue
> reported as an improvement and setting the stage for patch to be attached.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://www.stripesframework.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
------------------------------------------------------------------------------
The Next 800 Companies to Lead America's Growth: New Video Whitepaper
David G. Thomson, author of the best-selling book "Blueprint to a
Billion" shares his insights and actions to help propel your
business during the next growth cycle. Listen Now!
http://p.sf.net/sfu/SAP-dev2dev
_______________________________________________
Stripes-development mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/stripes-development