473,396 Members | 1,764 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

onunload not firing?

I'm using IE6 and I've just created a simple page with this event:
<body onunload="alert('sad')">
could someone tell me if this works for you if you have IE 6? I've
tested this in firefox and IE 7 and they both work fine with it. but on
the IE6 copy I'm testing, the event is fired only when the page is
refreshed. It's not fired when I close the page.
any ideas or suggestions?
thanks in advance

Jun 7 '06 #1
1 3211
TC

Kourosh wrote:
I'm using IE6 and I've just created a simple page with this event:
<body onunload="alert('sad')">

could someone tell me if this works for you if you have IE 6? I've
tested this in firefox and IE 7 and they both work fine with it. but on
the IE6 copy I'm testing, the event is fired only when the page is
refreshed. It's not fired when I close the page.


On my IE6, this works fine:

<html>
<body onunload="alert('sad')">
</body>
</html>

If I add an MOTW to suppress the security warnng, it still works fine:

<!-- saved from url=(0014)about:internet -->
<html>
<body onunload="alert('sad')">
</body>
</html>

Maybe you have disabled scripting in the browser somehow?

HTH,
TC (MVP MSAccess)
http://tc2.atspace.com

Jun 8 '06 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: Simon Wigzell | last post by:
I'm using OnUnLoad in my body statement to redirect to a function to clean things up if someone exits a form by closing it from outside the webpage code - e.g. by not using the cancel or save and...
6
by: kaeli | last post by:
Hey guys, This error occurs ONLY in Netscape 7.0. Not in 7.1. So, I think it's a bug. Buuuut... Has anyone had this problem or know of a fix? When attempting to have an onunload function...
3
by: Laurent | last post by:
I am trying to use the onunload event to know when the user closes a popup by receiving a request on the web server. I have a main page from where the user opens a popup. What I want is when the...
9
by: Joakim Braun | last post by:
Unonload doesn't get much time when quitting the browser. So how can you do time-consuming actions then? I'm doing a web-based MySQL interface. Records are presented as tables of links. The...
1
by: Tim Arview | last post by:
Hi, I'm trying to create an exit popup that doesn't require anything added to the body tag. In other words, I don't want to say <body onunload="foo">. I just want to have window.onunload="foo"...
8
banning
by: banning | last post by:
<!-- Google maps has a tendency to wreck things. Load it LAST! It can interfere with other stuff loading --> <script...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.