You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@struts.apache.org by "Tim Stavenger (JIRA)" <ji...@apache.org> on 2009/07/30 16:50:59 UTC
[jira] Created: (WW-3209) Select components do not allow setting
attributes and JavaScript events on tags
Select components do not allow setting attributes and JavaScript events on <option /> tags
------------------------------------------------------------------------------------------
Key: WW-3209
URL: https://issues.apache.org/struts/browse/WW-3209
Project: Struts 2
Issue Type: Improvement
Components: Other
Affects Versions: 2.1.7
Reporter: Tim Stavenger
Priority: Minor
The combobox, select, optiontransferselect and any other tag that uses the <option /> or <optgroup /> tags do not allow you to set any additional attributes or JavaScript events besides the value posted back to the server and the value displayed to the user.
I had a scenario where the client wanted a hover to appear for each option in a multi-select component. I could have used the title attribute or the onchange/onclick events of <option />, but couldn't because Struts didn't support them (at least without modifying Struts). I ended up with a different implementation that listened for onchange and onclick events for the <select /> tag. It works, but isn't exactly what the user wanted. I could also have just manually used the <select> and <option> tag, but would have lost everything else Struts provides.
See http://www.w3schools.com/tags/tag_optgroup.asp and http://www.w3schools.com/tags/tag_option.asp for the available attributes and events.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (WW-3209) Select components do not allow setting
attributes and JavaScript events on tags
Posted by "Wes Wannemacher (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/struts/browse/WW-3209?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Wes Wannemacher updated WW-3209:
--------------------------------
Fix Version/s: 2.1.9
Although we don't make strict w3c compliance a goal, I think this would be useful and fairly easy to implement. I'd like to see this in the next release (not enough time to make it happen for 2.1.8)
> Select components do not allow setting attributes and JavaScript events on <option /> tags
> ------------------------------------------------------------------------------------------
>
> Key: WW-3209
> URL: https://issues.apache.org/struts/browse/WW-3209
> Project: Struts 2
> Issue Type: Improvement
> Components: Other
> Affects Versions: 2.1.7
> Reporter: Tim Stavenger
> Priority: Minor
> Fix For: 2.1.9
>
>
> The combobox, select, optiontransferselect and any other tag that uses the <option /> or <optgroup /> tags do not allow you to set any additional attributes or JavaScript events besides the value posted back to the server and the value displayed to the user.
> I had a scenario where the client wanted a hover to appear for each option in a multi-select component. I could have used the title attribute or the onchange/onclick events of <option />, but couldn't because Struts didn't support them (at least without modifying Struts). I ended up with a different implementation that listened for onchange and onclick events for the <select /> tag. It works, but isn't exactly what the user wanted. I could also have just manually used the <select> and <option> tag, but would have lost everything else Struts provides.
> See http://www.w3schools.com/tags/tag_optgroup.asp and http://www.w3schools.com/tags/tag_option.asp for the available attributes and events.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.