Google Answers Logo
View Question
 
Q: My website crashes IE ( Answered,   2 Comments )
Question  
Subject: My website crashes IE
Category: Computers > Internet
Asked by: beavis-ga
List Price: $10.00
Posted: 13 May 2002 17:13 PDT
Expires: 20 May 2002 17:13 PDT
Question ID: 16063
I have a website that sometimes crashes people's IE browsers. My site
uses quite a bit of Javascript and I suspect that this is related to
the problem. The crashes occur with several different versions of IE
and like any good bug are not predictable (not always at the same
place and not easily reproducible). Upgrading the browser is not an
option since this website is used by many different people. Not using
JS is also not an option.

What I am hoping to do is "tune" my Javascript to avoid these
problems. That is, change the parts that cause the crashes. What I
would like is a big list of HTML and JS that crash IE and workarounds
to avoid these crashes.

A (made up) example might look like this:
  Resizing a DIV while the page is loading crashes IE5 20% of the
time.
  Waiting for the page to load eliminates the crash.
Answer  
Subject: Re: My website crashes IE
Answered By: netcrazy-ga on 13 May 2002 18:52 PDT
 
Hi beavis,
First of all, let me start by saying that there is no such list
available on net which can give you all the events which causes the IE
to crash and their workarounds. I've tried to list many such cases by
searcing the net. As a suggestion, if you ask your users to upgrade
their browsers to IE 5, they can avoid most of the crashes.

Here are some of the cases:

1. If you create an "is" object on IE3 for the Mac, the first time the
page is loaded, the code will work fine, however any reloads of the
page will cause the browser to crash
Workaround :To get around this on IE3 for the Mac, we don't create an
"is" object; instead, we create bunch of boolean variables which have
similar names
Another possible workaround is to use the object oriented code on all
other browsers but wrap it in a check which avoids executing the
object oriented code on IE3 for the Mac. This preserves the object
oriented design of the code but requires an extra boolean check like
if (!isIE3Mac && is_nav4up) each time you reference the is object.
http://www.mozilla.org/docs/web-developer/sniffer/browser_type.html

2. Check out this page too. It has some HTML code which can crash your
IE. So the workaround is do not code as given on this page:
http://www.insecure.org/sploits/ie40.bugs.html

3. Microsoft Internet Explorer Can Be Crashed By Malicious
'location.replace' Javascript
Solution:  No solution was available at the time of this entry. But I
think, in the latest version of IE, this has been fixed.
http://securitytracker.com/alerts/2002/Mar/1003856.html

4. IE4 has a layout bug. You'll need to load your menus before the
window's onLoad event handler is called, because IE4 will most often
crash when the Menu component tries to use the JScript innerHTML
property for CSS-P objects after the page is laid out, especially with
multiple menus.
Solution: Load your menus early and you should be fine. 

5. Due to users installing IE4 final without uninstalling IE4 beta, an
error is caused when clicking a link to open a pop-up window.
Microsoft Internet Explorer 4 has errors with this line:
          popupWin = window.open("file.html", "remote"); 
Another weird twist to this case is that it doesn't always happen.
Infact, many people report that the browser crashes after recieving
the error "No such interface supported".
Solution:The best solution is to uninstall the browser and reinstall
just IE4 final. This will solve the problem and solve other
undiscovered problems.

6. A page uses frames to host JavaScript code on the main page, and
uses a "main" subframe to display rendered contents calculated by the
JavaScript code. In addition, the displayed page has event handlers on
various actions that could be cause for the page to be redrawn, by
executing a function in the
parent frame. So, if we use an "onChange" event handler in a text
input box, and the user enters data and TABS out of the box, the
onChange event handler is invoked. If the event handler redraws the
page, IE will crash.
Solution: If you change the data and then CLICK on the page, the event
handler is also invoked, the page is redrawn, but the browser does not
crash.
http://security-archive.merton.ox.ac.uk/bugtraq-199909/0280.html

7. Various JavaScript bugs or events that can cause IE to crash can be
found here:
  http://search.atomz.com/search/?sp-q=bugs+with+JS+to+crash+IE&sp-a=sp1001071c

Search Terms used:
tuning of javascript to avoid IE crashing
://www.google.com/search?q=tuning+of+javascript+to+avoid+IE+crashing&btnG=Google+Search&hl=en

javascript events that can crash IE browser
://www.google.com/search?hl=en&q=javascript+events+that+can+crash+IE+browser&btnG=Google+Search

how to avoid IE browser from crashing
http://search.dogpile.com/texis/search?q=how+to+avoid+IE+browser+from+crashing&geo=no&fs=web

I hope this will help you in making your code more robust and
Crash-Free.

Regards
netcrazy

Request for Answer Clarification by beavis-ga on 13 May 2002 19:09 PDT
Actually, all of the users are running IE 5 or newer. (5, 5.5, 6) I'm
not looking for malicious crashes, just accidental ones.

Clarification of Answer by netcrazy-ga on 14 May 2002 06:27 PDT
Hi,
As I wrote to you earlier that the specific "accidental" cases will
depend on your code only. As mmi-ga mentioned in the comments that its
better you get your code reviewd by any JS forum or by someone else.
This will give an insight of your code and also will fasten the
process of getting the bugs causing IE to crash. I'll suggest you to
ask someone to do a stress testing of your code. Since the person
performing the testing will not be you, more bugs can be found in no
time.
Also, you can post your code over Google so that some researcher can
have a look on it.
I hope this will help you. 
Regards.
Comments  
Subject: Re: My website crashes IE
From: mmi-ga on 13 May 2002 21:59 PDT
 
hey beavis - have you tried having someone look at the code - you may
meet with success more quickly that way - in a comment on an earlier
question, I suggested the enquirer seek help at one of the many (well
several good ones, anyway) online web development forums - the two I
suggested are the ones I'm familiar with, so to be fair, I don't think
I should give them any more publicity - try looking through this
return from Google:

://www.google.com/search?hl=en&q=javascript+forums+resources :-)
Subject: Re: My website crashes IE
From: mmi-ga on 13 May 2002 22:17 PDT
 
guess the formatting wants t' wrap that url

Important Disclaimer: Answers and comments provided on Google Answers are general information, and are not intended to substitute for informed professional medical, psychiatric, psychological, tax, legal, investment, accounting, or other professional advice. Google does not endorse, and expressly disclaims liability for any product, manufacturer, distributor, service or service provider mentioned or any opinion expressed in answers or comments. Please read carefully the Google Answers Terms of Service.

If you feel that you have found inappropriate content, please let us know by emailing us at answers-support@google.com with the question ID listed above. Thank you.
Search Google Answers for
Google Answers  


Google Home - Answers FAQ - Terms of Service - Privacy Policy