[ http://issues.apache.org/jira/browse/BEEHIVE-407?page=history ]
Daryl Olander reassigned BEEHIVE-407:
-------------------------------------
Assign To: Daryl Olander
> form must have tagId set to use focus attribute
> -----------------------------------------------
>
> Key: BEEHIVE-407
> URL: http://issues.apache.org/jira/browse/BEEHIVE-407
> Project: Beehive
> Type: Bug
> Components: NetUI
> Versions: V1
> Reporter: Krista Baker
> Assignee: Daryl Olander
>
> The focus attribute on the netui:form html tag generates JavaScript errors in
> Firefox and IE when the form tag does not have a tagId
> JSP Test Code:
> <netui:form action="begin" focus="buttonTag">
> <netui:button action="begin" tagId="buttonTag">Focus</netui:button>
> </netui:form>
> Expected results:
> The focus attribute and generated javaScript should work the same whether the
> form tag has a tagId or not.
> Actual results:
> The following JavaScript error is output (firefox):
> Error: document.forms.Netui_Form_0 has no properties
> Actual JavaScript:
> <script language="JavaScript" type="text/JavaScript">
> // set the focus on a field within the named form
> if (document.forms["Netui_Form_0"]["actionOverride:begin"].type != "hidden")
> document.forms["Netui_Form_0"]["actionOverride:begin"].focus();
> Working JavaScript with form tagId="one":
> // set the focus on a field within the named form
> if (document.forms["one"]["actionOverride:begin"].type != "hidden")
> document.forms["one"]["actionOverride:begin"].focus();
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
If you want more information on JIRA, or have a bug to report see:
http://www.atlassian.com/software/jira