gravityboy
gravityboy

Reputation: 817

Why does alert(navigator.appName) Lock-Up Safari

This...

alert(navigator.appName); 

...alerts the browser type in every other browser (google, opera, firefox, IE) but it completely locks-up safari and I have to go in and "end program" to stop it. Does any body know why?

here is the whole piece of code...

<script language="JavaScript">   
if (navigator.appName.indexOf("Netscape")> -1){  
    document.animation.ttt.rows=5;document.animation.ttt.cols=9;}// 
//alert(navigator.appName);
</script>

if I comment it out it is fine. If I alert it, it locks (only in Safari). Crazy?

(edit) updated to latest version... safari 5.0.3 (7533.19.4) no effect on lock up

Upvotes: 0

Views: 645

Answers (1)

Babiker
Babiker

Reputation: 18798

Works fine in my Safari 5.0.3. Which version are you using? It has to be the code before or after the alert. For starters check your loops.

Upvotes: 1

Related Questions