Closed
Bug 274744
Opened 20 years ago
Closed 20 years ago
Javascript context lost in sidebar
Categories
(Firefox :: Bookmarks & History, defect)
Tracking
()
RESOLVED
WORKSFORME
People
(Reporter: o.oudin, Assigned: vladimir+bm)
References
()
Details
Attachments
(1 file)
1.48 KB,
text/html
|
Details |
There is a bug when a page loaded in seidebar uses javascript, it seems that all javascript objects and functions are lost : I've a bookmark loaded in the sidebar, which contains custom javascript functions. In the sidebar theses functions are losts when the page is loaded (but are ok during loading). Here is the complete description : - This page works well when opened with firebox in standard mode - Bug : if you put this page in your sidebar, it seems that firefox loose all javascript objects and functions. This little example reproduce this behaviour step 1 : we define a function and call it during loading -> it works ! step 2 : we try to do the same things directly without calling our function -> it works (so javascript still works) step 3 : we call our function after the page is loaded (with a link) -> It hangs ! The javacript console says our function is not defined. - More weird now : step 4 : open the same page in firefox main area (not in sidebar) AND in the sidebar, and retest calling the function by clicking in the sidebar-> it works ! In fact, le sidebar page uses javascript context defined in the main area page. We test with more complicated objects, clicking in the sidebar changes the page in the main area ! Here is the sample to reproduce this always (tested on 1.0PR, 1.0RC1, 1.0RC2 and 1.0) : <html> <head> <script language="javascript"> // We define a little function function test(tmpString) { alert(tmpString); } // We test our function during page loading test('Alert call in function \'test\' during loading'); </script> </head> <body> <!-- link to call our function --> Alert call in function 'test': <a href="javascript:test('Alert call in function \'test\'');">test</a> <br> <!-- a simple javascript test --> Alert call directly : <a href="javascript:alert('Alert call directly');">test</a> </body> </html>
Reporter | ||
Comment 1•20 years ago
|
||
Comment 2•20 years ago
|
||
Links in the sidebar target the main content area, including javascript: links. Add a target="_self" to your test link, and it works as expected.
Status: UNCONFIRMED → RESOLVED
Closed: 20 years ago
Resolution: --- → WORKSFORME
Comment 3•18 years ago
|
||
sorry for bugspam, long-overdue mass reassign of ancient QA contact bugs, filter on "beltznerLovesGoats" to get rid of this mass change
QA Contact: mconnor → bookmarks
You need to log in
before you can comment on or make changes to this bug.
Description
•