Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Fixed
-
2.1.17
-
None
-
None
Description
When submitting an Ajax request that was triggered by an element with a name, but without an ID, a Javascript error will be thrown in the nodeIdOrName() function in _Dom.js.
The code calls the getElementsByName() function on "this", which throws an error that getElementsByName() is not defined for "this". It should call document.getElementsByName(), same as the byIdOrName() function.
251 //last check for uniqueness
252 if (this.getElementsByName(elementId).length > 1)
This was noticed when using the ICEfaces 3.3 data table in their compatibility component suite, which uses hidden fields without IDs to submit the selection of rows.
If you want an example that reproduces this error I can create one, but I think static analysis of the code is sufficient in this case.
The problem is also present in trunk.