| Adding File Upload to your HTML Form |
You can add the Appletfile Upload Applet to an existing HTML form by following these four steps:
Here is a simple example form:
<FORM ACTION="upload.asp" onSubmit="return processUpload(this)">
<INPUT TYPE="submit" VALUE="Upload">
</FORM>
<APPLET CODE="com/infomentum/Appletfile/FileUpload.class"
ARCHIVE=FileUpload.jar
NAME=FileUpload CODEBASE="/Appletfile/classes" WIDTH=420 HEIGHT=180 MAYSCRIPT>
<PARAM NAME="cabbase" VALUE="/Appletfile/classes/FileUpload.cab">
<PARAM NAME="directory" VALUE="C:\My Documents">
</APPLET>
In this example, the parameter directory is used to specify "C:\My Documents" as the default directory so that the first time the user adds a file, the Browse dialog will open in this directory.
| Using Drag N Drop File Upload |
By Default the drag n drop is ready to be used. Simply click on the applet to gain focus and then drag your file or folders to the applet file list. Thats all there is to it.