Issue Details (XML | Word | Printable)

Key: STR-2826
Type: Bug Bug
Status: Closed Closed
Resolution: Fixed
Priority: Major Major
Assignee: Don Brown
Reporter: Zarar Siddiqi
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
Struts 1

If a field's display property is set to 'none' using CSS or JavaScript, the focus code fails.

Created: 08/Apr/06 04:44 AM   Updated: 28/Apr/06 11:48 PM
Component/s: Tag Libraries
Affects Version/s: 1.2.9
Fix Version/s: 1.3.3

Time Tracking:
Not Specified

File Attachments:
  Size
Text File focusControl_css_dispay_bug_fix.patch 2006-04-08 04:44 AM Zarar Siddiqi 0.2 kB
Environment:
Operating System: other
Platform: Other

Bugzilla Id: 39249
Resolution Date: 28/Apr/06 11:59 AM
Labels:


 Description  « Hide
If a field's display property is set to 'none' using CSS or JavaScript, the
current code still tries to give the field focus which will result in an error
in IE.

A patch is for the org.apache.struts.taglib.html.FormTag.java file and is attached:

663c663
< " if (focusControl.type != \"hidden\" && !focusControl.disabled) {");
---
> " if (focusControl.type != \"hidden\" && !focusControl.disabled
&& focusControl.style.display != \"none\") {");

 All   Comments   Work Log   Change History   Subversion Commits      Sort Order: Ascending order - Click to sort in descending order
Zarar Siddiqi added a comment - 08/Apr/06 04:44 AM
Created an attachment (id=18044)
Patch to apply to org.apache.struts.taglib.html.FormTag to fix focus() bug.

Don Brown added a comment - 28/Apr/06 11:59 AM
The patch has been applied against trunk, so give it a shot and close the ticket if you found it fixed. Thanks for the patch!

Zarar Siddiqi added a comment - 28/Apr/06 10:28 PM
This worked for me. Thanks. Can't find the option to 'close' this issue so I'll leave that to you...

Don Brown added a comment - 28/Apr/06 11:06 PM
Ok, try again, the permissions should be fixed.

Zarar Siddiqi added a comment - 28/Apr/06 11:48 PM
This is now fixed.