Closed
Bug 354427
Opened 19 years ago
Closed 15 years ago
Javascript event handlers are being dropped
Categories
(Firefox :: General, defect)
Tracking
()
RESOLVED
INCOMPLETE
People
(Reporter: shaun, Unassigned)
Details
(Whiteboard: [CLOSEME 2010-11-01])
User-Agent: Mozilla/5.0 (Macintosh; U; PPC Mac OS X Mach-O; en-US; rv:1.8.0.7) Gecko/20060909 Firefox/1.5.0.7
Build Identifier: Mozilla/5.0 (Macintosh; U; PPC Mac OS X Mach-O; en-US; rv:1.8.0.7) Gecko/20060909 Firefox/1.5.0.7
Html emitted from Javascript using document.write is loosing assigned Javascript event handlers, onblur, onfocus, onmouseup etc. are being dropped.
Tested on OS X, 10.4.7, PowerPC G4.
Also reported to me by users running Windows(unsure if XP or win2000).
Affected Versions: Firefox 1.5.07, 1.5.0.8, 2.0-rc1.
Unaffected Versions: Firefox 1.5.0.4 and 1.5.0.6.(Didn't test 1.5.0.5.)
Reproduceable: Always with version 1.5.0.7 and higher.
The problem occurs within a web application written in JS.
I am trying to get a Demo app deployed so the firefox engineers can view the behaviour 1st hand.
Unfortunatley my attempts to create a simple test case have been unsuccessful so far. I will continue to try and create a simple test case.
I understand that not being able to provide a simple set of steps to reproduce this problem may result in this bug being ignored or put as a low priority but I wanted to give you guys and gals a heads-ups sooner rather than later.
I still need to organise a location to deploy the Javascript applicaton and will update this bug with a URL you can use to view the behaviour ASAP.
Reproducible: Always
Steps to Reproduce:
1. Launch the javascript application at: [URL coming]
2. Select the thumbnail view of a page.(top left). Stamps are displayed on the main canvas(right side).
3. Select one of the grey stamps(not the green ones), textfields are rendered in frame(bottom left). This is where the problem occurs. Each textfield is assigned custom event handlers. A Mouseover these fields should set the the selected checkbox to Change or OK. The checkbox "OK" should be checked if no text is in the textfield. If the user types into the question fields the selected checkbox should become "Change".
Note: It should NOT be possible to have both "Change" and "OK" checkboxes selected at the same time, however it is possible to select both when the event handlers have been dropped ie) the bug allows the implementation of the business logic to fail.
NOTE: This works correctly on FF version 1.5.0.4 and 1.5.0.6, but not 1.5.0.7 and above.
4. Mousing over these fields randomly results in the event handlers for all the fields of the panel to be "lost" or "dropped" (I Confimed this by using a Firefox JS debugger extension called Firebug, that is, firebug shows native code methods as the assigned event handlers, after the problem arises).
The problem also occurs sometimes when adding a new stamp to the page.
ie) select the stamps tab(top left) click a stamp, draw stamp box square on page. Mouseover text areas and sometimes the event handlers are lost.
Actual Results:
Event handlers are not fired sometimes as they have been "lost".
Expected Results:
Event handler functions should be invoked.
This application uses multiple frames and framesets. Is built using the DynAPI Javascript API, although I dont think this is related to the problem as the app
has been working correctly with previous versions of Firefox, it was only 1.5.0.7 and up where problems are experienced.
I have marked the severity as "major". For our clients its a big problem as a feature of the application is broken and they now have to run an older version of Firefox for it to work as expected.
I will add a comment with a URL to a demo of the problem ASAP.
The problem can be observed at the following URL,
http://tinyurl.com/flfhb
If you have any trouble accessing this site please let me know.
I'm getting dropped onclick handlers on a page of mine in Firefox. I'll see later if I can narrow down when it happens in the script. Events fire just fine the first few times I click, but the onclick property becomes undefined for several nearby links after I've been clicking on them for a while.
Comment 3•18 years ago
|
||
I have a web application where I see the same behavior in Firefox 2.0.0.1 on Windows XP and Mac. The page content is written by document.write, and event handlers are attached just fine - but have sometimes (say 1 out of 5 times) disappared when the user starts to interact with the page.
It is not just event handlers that disappear; also any other properties set on the document or its element (but window properties remain).
Ideas for workarounds would be highly appreciated.
FWIW I have rewritten a small section of our app to assign the event handlers directly to the html elements rather than using the DOM to assign the event handlers. This seems to work ok, but I cant say for sure thats its 100% solid as its an intermittent problem anyway.
However, this is not an acceptable workaround for us as our app is too large to rewrite all the functionality in this manner.
One thing I have noticed is that when my machines resources are stretched to the limit the problem seems to occur more often.
I have tried to figure out what the cause of the problem might be by diffing the source code from 1.5.0.6 & 1.5.0.7. I came across one block of code that was added to the source in 0.7 that might be related, but I don't know enough about the source to really understand what its doing.
My attempts to fix this(in the firefox source) have so far been totally unsuccessful.
Comment 5•15 years ago
|
||
This is a mass search for bugs that are in the Firefox General component, are UNCO, and have not been changed for 1000 days and have an unspecified version.
Reporter, can you please update to Firefox 3.6.10, create a fresh profile, http://support.mozilla.com/en-US/kb/managing+profiles, and test again. If you still see the bug, please update this bug. If the issue is gone, please set the resolution to RESOLVED > WORKSFORME.
Whiteboard: [CLOSEME 2010-11-01]
Comment 6•15 years ago
|
||
No reply from reporter, INCOMPLETE. Please retest with Firefox 3.6.12 or later and a new profile (http://support.mozilla.com/kb/Managing+profiles). If you continue to see this issue with the newest firefox and a new profile, then please comment on this bug.
Status: UNCONFIRMED → RESOLVED
Closed: 15 years ago
Resolution: --- → INCOMPLETE
You need to log in
before you can comment on or make changes to this bug.
Description
•