Microsoft KB Archive/811577

= The onload event handler does not fire when you return to a page =

Article ID: 811577

Article Last Modified on 1/26/2004

-

APPLIES TO


 * Microsoft Internet Explorer 5.2 for Mac OS X
 * Microsoft Internet Explorer 5.1 for Macintosh

-





SYMPTOMS
When you follow a link in a frameset that targets the top frame, and then you go back to the page where you started, the onload event handler does not fire.



RESOLUTION
To resolve this problem, add an onunload event handler. This turns on the onload event handler so that it will fire (although how it does this is not known).



STATUS
Microsoft has confirmed that this is a bug in the Microsoft products that are listed in the &quot;Applies to&quot; section of this article.



Steps to reproduce the behavior
  Save frame.htm and test.htm to a Web server.

frame.htm   test.htm    function testMessage {   alert(&quot;onload&quot;); }    test</a> </BODY> </HTML> </li> <li>Use Microsoft Internet Explorer for Macintosh to view frame.htm. A dialog box appears that indicates that the onload event handler for the frame has fired.</li> <li>Click the link to view another Web page in the top frame.</li> <li>Click the Back button. The onload event handler does not fire.</li> <li> If you add the following onunload event handler, the problem does not occur. <BODY onload=&quot;testMessage&quot; onunload=&quot;&quot;> </li></ol>

Additional query words: MacIE

Keywords: kbbug kbhtml kbdhtml KB811577

-

[mailto:TECHNET@MICROSOFT.COM Send feedback to Microsoft]

© Microsoft Corporation. All rights reserved.