Problem about downloading JAR file

Hi,

I met an infrequent problem about downloading jar file. Is there anybody can help me?

Similar code as belows:
<APPLET WIDTH="500" HEIGHT="350" NAME="MyApplet" codebase="http://x.x.x.x/">
<PARAM NAME="ARCHIVE" VALUE="Applet.jar">
<PARAM NAME="CODE" VALUE="Applet.class">
</APPLET>

The problem is it will translate the codebase by some DNS server, (right?)
but it can NOT connect the DNS server now because the WEB server here is in
an intranet. The jar file can be download finally after about 6-20 seconds,
researched by sniffer, the time wasted in connecting the DNS(fail and retry
several times).
Analysis: Cause IE can consider the x.x.x.x as an IP, why it doesn't consider
the codebase as an IP but an URL? I think the codebase tag is transacted by JVM
but not IE (right?). Should it possible to let the JVM consider the codebase
as an IP but not URL(need to translate by DNS)?

thx!
MJ
popxwAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

CEHJCommented:
Why are you not using the customary codebase="." (or some other relative url) btw?
0
Tommy BraasCommented:
This is what I found on w3.org regarding the applet tag;

"13.4 Including an applet: the APPLET element
APPLET is deprecated (with all its attributes) in favor of OBJECT.

See the Transitional DTD for the formal definition.

Attribute definitions

codebase = uri [CT]
This attribute specifies the base URI for the applet. If this attribute is not specified, then it defaults the same base URI as for the current document. Values for this attribute may only refer to subdirectories of the directory containing the current document. Note. While the restriction on subdirectories is a departure from common practice and the HTML 3.2 specification, the HTML Working Group has chosen to leave the restriction in this version of the specification for security reasons."

So, basically, it conforms with the standard sand box approach to applets. Can only retreive files from the current server.

My advice to you would be to create a signed applet, that then loads whatever classes you want from the remote jar. Or even better, host the jar on your own server!
0
Tommy BraasCommented:
Oh, and you need to specify the 'code' attribute to tell the browser which class to load, e.g. code="MyApplet.class".

You can try the 'archive' parameter to specify where to load the jar from, it might actually work loading from a different site...

The 'name' you specified is only to allow other applets to access that applet by name. It does not tell the browser which class to load for the applet.

You can find more information at;
http://www.w3.org/TR/REC-html40/struct/objects.html#h-13.4

Based on your html code, try this;

<APPLET WIDTH="500" HEIGHT="350" CODE="MyApplet.class" NAME="MyApplet" ARCHIVE="http://x.x.x.x/">
<PARAM NAME="ARCHIVE" VALUE="Applet.jar">
<PARAM NAME="CODE" VALUE="Applet.class">
</APPLET>
0
Cloud Class® Course: CompTIA Healthcare IT Tech

This course will help prep you to earn the CompTIA Healthcare IT Technician certification showing that you have the knowledge and skills needed to succeed in installing, managing, and troubleshooting IT systems in medical and clinical settings.

popxwAuthor Commented:
Hi, CEHJ

I've tried to use codebase=".", but the same result.

MJ
0
popxwAuthor Commented:
Hi, CEHJ

I've tried to use codebase=".", but the same result.

MJ
0
CleanupPingCommented:
popxw:
This old question needs to be finalized -- accept an answer, split points, or get a refund.  For information on your options, please click here-> http:/help/closing.jsp#1 
EXPERTS:
Post your closing recommendations!  No comment means you don't care.
0
tomboshellCommented:
No comment has been added lately, so it's time to clean up this TA.
I will leave a recommendation in the Cleanup topic area that this question is:
SPLIT between CEHJ and orangehead911 because I am unsure of the results/solutions offered.  orangehead911 offered some good information and CEHJ tryed to get the questioner to format the codebase for the intranet.  If anyone has more information or clarifications then PLEASE contribute.

Please leave any comments here within the next seven days.

PLEASE DO NOT ACCEPT THIS COMMENT AS AN ANSWER!

Thomas Boshell
EE Cleanup Volunteer
0
Computer101Commented:
PAQed, with points refunded (200)

Computer101
E-E Admin
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Java

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.