PDA

View Full Version : Java problem?


VSAngela
6-26-02, 07:12 AM
I wasn't sure which forum to post this in, but this one seems most appropriate...

I've worked up a great-looking menu to use on my website. It works fine on my machine, but when I upload it, it refuses to load at all. Everything is uploaded into the same relative space on the server that it's located at on my 'puter, so everything should work, right?

Well, here's what my Java console is telling me:

IOException Loading Archive: http://www.virtual-scrapbook.com/menu/apPopupMenu.jar
java.io.FileNotFoundException: www.virtual-scrapbook.com:80//menu/apPopupMenu.jar
at com/ms/net/wininet/http/HttpInputStream.connect
at com/ms/net/wininet/http/HttpInputStream.<init>
at com/ms/net/wininet/http/HttpURLConnection.createInputStream
at com/ms/net/wininet/WininetURLConnection.getInputStream
at com/ms/vm/loader/JarArchiveSet.loadNextJar
at com/ms/vm/loader/JarArchiveSet.getResourceBits
at com/ms/vm/loader/JarArchiveSet.getClassData
at com/ms/vm/loader/ResourceLoader.getClassData
at com/ms/vm/loader/URLClassLoader.findClass
at com/ms/vm/loader/URLClassLoader.loadClass
at com/ms/vm/loader/URLClassLoader.loadClass
at com/ms/applet/AppletPanel.securedClassLoad
at com/ms/applet/AppletPanel.processSentEvent
at com/ms/applet/AppletPanel.processSentEvent
at com/ms/applet/AppletPanel.run
at java/lang/Thread.run
java.lang.ClassNotFoundException: apPopupMenu
at com/ms/vm/loader/URLClassLoader.loadClass
at com/ms/vm/loader/URLClassLoader.loadClass
at com/ms/applet/AppletPanel.securedClassLoad
at com/ms/applet/AppletPanel.processSentEvent
at com/ms/applet/AppletPanel.processSentEvent
at com/ms/applet/AppletPanel.run
at java/lang/Thread.run

Any thoughts? Thanks in advance...

RSaucier
6-26-02, 08:23 AM
Since I'm a Java idiot, I have to ask a stupid question: Was it developed with J++ by any chance?

Robert

VSAngela
6-26-02, 09:09 AM
Eh, I have no clue. The site I got the menu from may say something about that... http://www.apycom.com

RSaucier
6-26-02, 09:43 AM
Next stupid question... :)

have you tried placing the menu page and content in the root of your website instead of under the "menu" directory?

Robert

muijefr
6-26-02, 10:15 AM
But might the class(s) needed to run the application not be available on your site. As you've indicated they are in your PC but are they in/on your site or packaged in a library for access.

blurchy
6-26-02, 11:44 AM
hi angela

tell me what site you have this on ?

some of them wont support java

powweb for instance doesnt support class files

ive done quite a bit with java applets and ive had

security exceptions on certain applets

the strangest thing is sometimes they just go away

i had one on my site called quoter that used to throw

a wobbler i deleted it all and uploaded all the class files

again ab few days later and that was that

the biggest thing with java is paths

anyway tell me more

VSAngela
6-26-02, 05:05 PM
Woo, multiple replies...

RSaucier: No, I haven't tried that...all the related menu files are in the same directory. Not sure how moving them to the root might make a difference...

Muijefr: Everything's uploaded, and in the appropriate directory.

Blurchy: Yes, my site is hosted on PowWeb (of course :) ). None of my files have a .class extension; there is an .htm, a .txt, and a .jar, and they're all in the same directory, so I'm calling simple filenames...there are no paths to deal with.

I think I'll try popping the .jar file into some other webspace I have...maybe PowWeb not supporting .class means they won't support .jar too. Will let you know how it goes.

Thanks for the input, guys...

alphadesk
6-26-02, 05:10 PM
VSAngela,

Powweb does support .class, it's .jar that may be in question.

http://www.alphadesk.net/java_slipper.htm

RoyW
6-26-02, 11:22 PM
Java is client side code. The code is downloaded from the server into the client browser and executed there.

Therefore .class and .jar are just static files to the server and should be served up if you reference them correctly.

Looking at the error (and clicking on the link it produces) the file
http://www.virtual-scrapbook.com/menu/apPopupMenu.jar
has either not been uploaded to the "/menu" directory or you did not upload it in "binary" mode (or the name may be incorrect - case is sensitive)

Also - it may depend on the <ARCHIVE= attribute of the <APPLET> tag. Can you post the applet parameters (or the page that has the menu)?

VSAngela
6-27-02, 01:00 AM
See? I knew it had to be something completely and altogether silly...

My WS_FTP forces lowercase filenames, and the reference the .jar file had those couple of capital letters in it.

*smacks forehead*

The menu is working perfectly now. Thanks, guys. :D

blurchy
6-27-02, 09:00 AM
hey there

alphadesk whenever i asked powweb about .class files

different people have told me over and over they didnt support

.class files i almost didnt sign up here because of it

is this a recent addition ?

p.s. cool site :)

alphadesk
6-27-02, 11:15 AM
thanks blurchy,

Powweb has supported .class files for at least 9 months. That's how long i've been here.

RoyW
6-27-02, 11:16 AM
The problem may be with whith question you are asking when you ask does PowWeb "Support Java"

Java code can be executed Server Side (Servlets) and Client Side (Applets). In both cases the code is held in ".class" or ".jar" files.

I do not know of any host that stops you using Applets. To do this they would specifically have to put in server side blocks on ".class" and ".jar" files. As applets run client side (in the users browser) they cannot compromise the security of the server. In applets the ".class" or ".jar" files are downloaded into the users browser and the code is executed there. Therefore all web hosts (including PowWeb judging by the examples on alphadesk's VSAgngela's websites) usually support Java Applets.

Java Servlets on the other hand run code on the server. The server has to be specifically set up to load and run Java Servlets. These could compromise the security of the server if the security settings are not set up correctly.

PowWeb does not support Java Servlets but they do support Perl/Cgi and PHP for server side processing.

Hope this makes things a little clearer.

blurchy
6-27-02, 04:57 PM
hi alphadesk

i cant believe how many people (5)

have told me powweb dont support .class files

well thats made my day :)

i always wanted to use this on my site

http://www.geocities.com/neutron_x2001/info/info.htm

youve prob seen it before it takes its text from a txt file

all u have to do is upload another text file and

it updates itself

someones just told me how to do that in flash too

cool

thanks alphadesk