File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Applets and the fly likes applets inside a folder Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Applets
Bookmark "applets inside a folder" Watch "applets inside a folder" New topic

applets inside a folder

John Mclain
Ranch Hand

Joined: Nov 04, 2007
Posts: 30
hello there,

i have number of applet class files inside a folder say classes/applets.
now these applet class files to be embedded in a jsp page, here classes is not the package name of applets,instead, it is simply a folder in which i want to put applets rather than in jar directly.
my problem is, if i jarred these class files along with folder like this

then what should i write in *Archieve* attribute of the applet tag to acces these file from jsp?
Ulf Dittmer

Joined: Mar 22, 2005
Posts: 42965
The archive attribute contains the name of the file; so it would be "myjar.jar" in this case. But that's only going to work if the directory structure in the jar file mirrors the package hierarchy of the classes. For example, if the package name is "com.example.myapplet", then "com" must be a top-level directory in the jar file. It can't be inside of another directory (like "classes").
John Mclain
Ranch Hand

Joined: Nov 04, 2007
Posts: 30
thanks for your reply

I agree. Here's the link:
subject: applets inside a folder
It's not a secret anymore!