Link to home
Start Free TrialLog in
Avatar of duncanb7
duncanb7

asked on

Java Applet Class file download

Dear Expert,
I get one Java Applet application running in my IE.The program is okay running in my IE really good.
I would like to download its class ile at http://data1.tutorial.com/applet/a.b.h.a.class
but it doesn't have such class file.

The question:
1-Is the normal if the class file name like a.b.h.a.class ?  could we have more than one "." in the class file name in Java ?
or a.b.h.a.class is equal to abha.class ?
2-If  codebase and code name is speficied with  http://data1.tutorial.com/applet/a.b.h.a.class
in <applet>  tab as follows provided by the site html page and If I can run the application succesfully with the class name,
I should be able to download it, But why not ?

Please advise

Duncan

<applet height="100%" width="100%" viewastext="" mayscript="" name="FullVer" codebase="http://data1.tutorial.com/applet/" code="a.b.h.a.class">

Open in new window

ASKER CERTIFIED SOLUTION
Avatar of CEHJ
CEHJ
Flag of United Kingdom of Great Britain and Northern Ireland image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of duncanb7
duncanb7

ASKER

Dear CEJI,

http://data1.tutorial.com/applet/a/b/h/a.class is still report as follows

The page cannot be found
The page you are looking for might have been removed, had its name changed, or is temporarily unavailable.

Please try the following:

    Make sure that the Web site address displayed in the address bar of your browser is spelled and formatted correctly.
    If you reached this page by clicking a link, contact the Web site administrator to alert them that the link is incorrectly formatted.
    Click the Back button to try another link.

HTTP Error 404 - File or directory not found.
Internet Information Services (IIS)

Technical Information (for support personnel)

    Go to Microsoft Product Support Services and perform a title search for the words HTTP and 404.
    Open IIS Help, which is accessible in IIS Manager (inetmgr), and search for topics titled Web Site Setup, Common Administrative Tasks, and About Custom Error Messages.
have you uploaded the class file to that directory?
You need to first of all determine which directory the applet is in - guessing won't help
It will also help if you post the actual address of the page including the correct domain
Sorry, The website is need  with login and password , and I just
type the path .../a/b/h/a/class at  working page's IE URL location bar after login successfully.
The cookies should be okay to upload the file since I am using the same IE window or object.


If you said correctly, it should be okay with .../a/b/h/a.class .

the only issue is authorization issue, if it is not allows  to access the site, it should report not HTTP:404 message
the server  will report to access deny or no access right such kind of message , Is it right ?
> the server  will report to access deny or no access right such kind of message , Is it right ?

thats right
Yes, authorisation works the same as any other page
Do you think ?

if I type the address .../a/b/h/a.class correctly, my cookies in the site will be sent to the server with
the address, or the server will request my IE automatically to send back the cookies for authentication check ?
So there is still two issue

1- class name in the path a.class or /ab/h/a/a.class or other we are missing
2- Cookies check by who, when and where before download the file ?

the class file would appear to not be in the correct directory
is it in /a.class
the only information about class file is here
 <applet height="100%" width="100%" viewastext="" mayscript="" name="FullVer" codebase="http://data1.tutorial.com/applet/" code="a.b.h.a.class">
Cookies won't be involved usually if you're downloading directly. Only when the applet is being displayed in the page as normal. Why would you WANT to just download the applet btw?
well that expects it to be in http://data1.tutorial.com/applet/a/b/h/a.class

If its not there then the applet has been deployed incorrectly
If it's in the right place, it will be at http://data1.tutorial.com/applet/a/b/h/a.class
After using http proxy software, I check all cookies is also sent to the server with http://data1.tutorial.com/a/b/h/a.class

So it seems only issue
actually, there is no such file  or a.b.h.a.class doesn't mean /a/b/h/a.class
The applet appears when you access the page in which it's set?
Yes, applet appear in my IE after login
Then the applet must be where it says it is. Try downloading it with something else
I 've download other file is okay, but the filename path has
a lot of variable for example
http:data1.tutorial.com/data.html?u=12&type=12&t=134780000&d=888593abvfdddffrfrr
And the variable is always changed so I need to re-click the button and go to http proxy
software to look at those http path.

Actually, the applet software is also provide to download the data file by Window dowload
Dialog menu and save as in PC. BUt the question I have 100 files needs to download,
I need to click a lot button to finish all of my download, so it is time cosumer.
I have tried to use VBA to do automation succesfully . But it is always occupying my computer
and I can't do other thing in PC during automation. So I thought
let it do it in my server by php if I know all data file full path and I can
access the website by curl in php

That is why I want to download applet class file and decomplier  to see how they generate
full file path such as
u= ?
type= ?
t= ?
d= ?

Probably  t= the time and date generated by javascript.
 
>>but the filename path has a lot of variable for example


The applet file path is fixed - there are no scripts involved, so you would need to put a fixed url in
And during php automation download programming in server and I will know
a lot of internet and software programming stuff.
The data file is just raw data like the one in csv file. The fata full path
with variable change with time and coding ,  I think it is  because of security issue from the vendor
>>The fata full path with variable change with time and coding,

The applet path can't change without redeployment of the applet
redeployment of the applet

What is that mean of the word of  redeployment of the applet
?
Do you understand my question?

The /a/b/h/a.class must exist and I am using firebug that also point
the <applet> when selct the applet working area.

If the class file is not existed I can not have applet display in my IE  
Finally get the answer


After using Firebug, found there is one more applet tag
before the one applet I want to locate. Without running
the first one as follow, second one /a/b/h/a.class file is not
existed because the first one will  do file extraction  from the
file name at codebase and archive. Now I can directly download those
two file data.cab and data.jar. After unzip  data.cab into my PC , there is  a lot of
 files and directories such as C:\\document Setting\Administrator\downloads\a\b\h\a.class
So a.class is found.

First one
==========
<applet ....
<param name=cabbase value="Data.cab">
<PARAM NAME="archive" VALUE="Data.jar">
Second one
================
<applet height="100%" width="100%" viewastext="" mayscript="" name="FullVer" codebase="http://data1.tutorial.com/applet/" code="a.b.h.a.class">

Now it seems I go to Java programing and debugging and PHP coding for next

Thanks for all of your reply this thread

duncan


Thanks for all of your reply
Now I am going to next and sleep

Bye Bye

Duncan
Yes, that's unusual. They might have done that so that it can be run either way. Of course, without knowing that there was also an archive tag jar, no advice is possible...
Sorry correct what I said for memo but the problem is also sovled
In firebug, it just show the code.
===========================
<tr><td>
<applet ....
<param name=cabbase value="Data.cab">
<PARAM NAME="archive" VALUE="Data.jar">
</td></tr>
<td></tr>
<tr><td>
<applet height="100%" width="100%" viewastext="" mayscript="" name="FullVer" codebase="http://data1.tutorial.com/applet/" code="a.b.h.a.class">
</td></tr>

But when using Charles' http proxy software,it show the second applet tag also with param
======================================================
<tr><td>
<applet ....
<param name=cabbase value="Data.cab">
<PARAM NAME="archive" VALUE="Data.jar">
</td></tr>
<td></tr>
<tr><td>
<applet height="100%" width="100%" viewastext="" mayscript="" name="FullVer" codebase="http://data1.tutorial.com/applet/" code="a.b.h.a.class">
<param name=cabbase value="Data.cab">
<PARAM NAME="archive" VALUE="Data.jar">
</td></tr>

SO in other words, when it includes param with archive and cabbase in applet tag  , applet will take care and
find the a.class file in jar file. and first tag of applet is no relation to second tag of applet.

For my memo only

Duncan