Solved

Java Applet causes browser window to close

Posted on 2004-08-08
8
1,016 Views
Last Modified: 2012-08-13
There is a particular site which is causing one of my clients no end of trouble.  The site is www.collectorcartraderonline.com and the problem is that when they click on any of the featured photo ads (and probably in a lot of other places as well), the browser window starts to load the page and then closes down.

Everything works fine on my machine.

His environment is Win XP Home running IE6 and all the latest critical and security patches are applied.  It also fails in exactly the same way whe he uses FireFox.

My environment (for what it's worth) is Win2000pro with IE6 (but not necessarily all the latest patches) but I've also tried on various other machines on my network (XPpro/IE6, Win98/IE5) and got no failures.

I found that if I saved the source of the page in question (from my machine) and copied it to a file on his machine (test.htm) then double clicking on that file produced exactly the same problem.  This at least gave me something I could try debugging and I found that the statement causing the problem was

<applet codebase="/applets/" Code="apPopupMenu" Archive="/applets/apPopupMenu.jar" Width="636" Height="38" MAYSCRIPT>

It's OK before it (alert("got here");) but not after it.

I assume that there's probably some setting on his machine which could be causing this but have little idea where to look.

Has anybody any ideas?  Indeed, is there a better topic to be seeking the answer to this question?
0
Comment
Question by:trentham
  • 3
  • 3
8 Comments
 
LVL 36

Expert Comment

by:Zyloch
ID: 11746674
Hi

Try
<applet codebase="/applets/" Code="apPopupMenu.class" Archive="/applets/apPopupMenu.jar" Width="636" Height="38" MAYSCRIPT>

Regards,
Zyloch
0
 

Author Comment

by:trentham
ID: 11746830
No, I'm afraid that has exactly the same effect; the browser closes down.
0
 
LVL 36

Expert Comment

by:Zyloch
ID: 11746916
Well, the code you posted seems to be pretty stable. Most likely, the window is closing because of something in your Java applet. What is MAYSCRIPT acting upon and what PARAMS do you have?

You might want to post your Java code in the Java TA as there are a lot of experienced people there. Finally, try taking out all the code on your page temporarily and only leave the <applet> and its <param>s. See if it is absolutely certian it's the applet.
0
Free Trending Threat Insights Every Day

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

 

Author Comment

by:trentham
ID: 11747270
I think I can't have made myself clear enough... this is not my code but code from the aforementioned site.  I just saved the source in order to highlight where abouts it was failing exactly.

I understand that this is a pretty major site for those into classic cars in the States and feel that if it had a problem there would have been many protests from its users so I assume that there is something causing a problem on this computer's settings.

I did try a test taking out all the JavaScript (leaving just the HTML and the applet) and it failed just as before.

I found another site which clearly uses applets and it shows the same behaviour on that machine so I assume it can't handle applets in some way.  Looking at the advanced internet properties it shows Use Java 2 v1.4.2_03 for <applet>.

I've also discovered that on IE's tools menu there is a 'Sun Java Console' which, if invoked, closes the browser in the same, sudden way..

My working machine shows (in installed programs)
     Java Runtime Environment 1.2

whilst the problem machine shows
     Java 2 Runtime Environment SE v1.4.0_01
     Java 2 Runtime Environment SE v1.4.2_03

Seeing that Sun are now showing the latest version as v1.4.2_05 I downloaded and installed this version and that cured the problem!

I can only assume that either v1.4.2_03 was problematic in some way or (perhaps more likely) that its installation on this machine was faulty in some way.

Still it's sorted now and my client will be a happy bunny.  thanks, Zyloch, for taking the time to look at this (enjoyed your profile btw :-))!

0
 
LVL 36

Expert Comment

by:Zyloch
ID: 11747571
Heh, sorry about the misunderstanding. (Of course, go and refund your points if you haven't already).
0
 

Author Comment

by:trentham
ID: 11748334
s'OK, it was an easy mistake to make!

Just in case anyone searches for a similar problem it may be worth summarising...

Problem: A particular web site caused the web browser to close

Additional Effect: Invoking Sun Java Console also causes the browser to close down

Solution: Upgrade Java runtime to latest (/ reinstall JRE?)

Cause: <applet ...> invokes Java Runtime Environment which is unable to run
   This is probably because either JRE is corrupt or the version contains bugs.
0
 

Accepted Solution

by:
CetusMOD earned 0 total points
ID: 11785679
Closed, 250 points refunded.
CetusMOD
Community Support Moderator
0

Featured Post

Maximize Your Threat Intelligence Reporting

Reporting is one of the most important and least talked about aspects of a world-class threat intelligence program. Here’s how to do it right.

Join & Write a Comment

Suggested Solutions

Bada platform is becoming more and more famous this days and people talking about same. Some friends included those who have bada OS mobile asked me "what is bada?"and "what its features?". That encouraged me to research and write this article. [st…
Today, still in the boom of Apple, PC's and products, nearly 50% of the computer users use Windows as graphical operating systems. If you are among those users who love windows, but are grappling to keep the system's hard drive optimized, then you s…
Shows how to create a shortcut to site-search Experts Exchange using Google in the Chrome browser. This eliminates the need to type out site:experts-exchange.com whenever you want to search the site. Launch the Search Engine Menu: In chrome, via you…
How to create a custom search shortcut to site-search Experts Exchange using Google in the Firefox browser. This eliminates the need to type out site:experts-exchange.com whenever you want to search the site. Launch your Bookmark Menu: Press 'Ctrl +…

744 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

16 Experts available now in Live!

Get 1:1 Help Now