[
http://www.stripesframework.org/jira/browse/STS-853?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12467#comment-12467
]
Cliff Jones commented on STS-853:
---------------------------------
I did read the entire discussion, which deals with XHTML vs HTML. That is not
the issue which I posted.
In no universe is the <optgroup> HTML generated by Stripes' taglib valid. I
suggest you follow the link which was provided in the issue and read the W3C
documentation. In addition, from
http://www.devguru.com/technologies/xhtml/7758.asp which states:
=========
The optgroup tag is used to group together related items in a pull-down form
control. An item can only be added to the group by using the option tag. Both
the optgroup and option tags must be used inside the opening and closing select
tags.
You cannot nest this tag.
*The separate closing tag is mandatory.* [emphasis added]
=========
Note the last line. Stripes does *not* provide a separate (mandatory) closing
tag. If you would just think about the <optgroup> tag for just a few seconds,
it would become obvious why it is required.
Again, to be absolutely clear, this is *NOT* about the use of "/>" versus ">"
which you said this was "like." It is about constructing a *group* of option
tags - hence the name of the tag. _With no closing tag there can be no group!_
Anyone else reading this, please chime in as apparently I am having trouble
getting across to Ben that there is a real problem, although I thought I was
pretty clear and detailed in my explanation and supporting documentation.
> Invalid <optgroup> HTML markup generated
> ----------------------------------------
>
> Key: STS-853
> URL: http://www.stripesframework.org/jira/browse/STS-853
> Project: Stripes
> Issue Type: Bug
> Components: Tag Library
> Affects Versions: Release 1.5.6
> Environment: Tomcat 6
> Reporter: Cliff Jones
> Assignee: Ben Gunter
> Priority: Minor
> Labels: options-collection
>
> The invalid <optgroup> tag is generated using <stripes:options-collection>
> tag when "partial" attribute is used within a <stripes:form> tag.
> (reformatted for readability)
> <select id="cboSupervisor" name="criteria.supervisor" class="DropBox"
> onchange="supervisorSelected(this);">
> <option value="">--- All ---</option>
> <optgroup label="Active" />
> <option value="204230">Bartlett, Roberta</option>
> <option value="306796">Beasley, Teresa</option>
> <option value="237550">Bersch, Alisha</option>
> <optgroup label="Retired" />
> <option value="251149">Acting TL, Ohm</option>
> <option value="155878">Auer, Kimberly</option>
> </select>
> The invalid use of non-body optgroup element results in the browser (IE)
> *not* providing the indentation for options belonging to that group when the
> select is replaced in the DOM via Ajax.
> Note: The CORRECT output is:
> <select id="cboSupervisor" name="criteria.supervisor" class="DropBox"
> onchange="supervisorSelected(this);">
> <option value="">--- All ---</option>
> <optgroup label="Active" >
> <option value="204230">Bartlett, Roberta</option>
> <option value="306796">Beasley, Teresa</option>
> <option value="237550">Bersch, Alisha</option>
> </optgroup>
> <optgroup label="Retired" >
> <option value="251149">Acting TL, Ohm</option>
> <option value="155878">Auer, Kimberly</option>
> </optgroup>
> </select>
> For further information on the correct use of <optgroup>, please see:
> http://www.w3schools.com/tags/tag_optgroup.asp
--
This message is automatically generated by JIRA.
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
------------------------------------------------------------------------------
All the data continuously generated in your IT infrastructure
contains a definitive record of customers, application performance,
security threats, fraudulent activity, and more. Splunk takes this
data and makes sense of it. IT sense. And common sense.
http://p.sf.net/sfu/splunk-novd2d
_______________________________________________
Stripes-development mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/stripes-development