WEB SITE: http://jupload.sourceforge.net/
This applet comes with source code. I take no responsibility for any damages caused by the usage of this applet. Use it at your own risk!
This applet is 'given' with the GPL licence.
Traditional HTML upload forms allow you to select and upload one file at a time. This restriction is unacceptable when it comes to uploading thousands of files within a single folder.
Java Multiple File Upload Applet (JUpload) takes care of this limited by allowing users to select and upload a whole directory and the files within it with a single click.
Main evolutions since V2, the original version, quite old now:
UploadPolicies makes it easy to configure these parameters:
Picture management is added by the PictureUploadPolicy. (see the Demo of the picture applet). This includes the following parameters:
Translations
The JUpload package contains the following languages: Arabic, Brazilian Portuguese, Bulgarian, Chinese (Simplified), Croatian, Czech, Danish, Dutch, English, Esperanto, French, German, Hebrew, Hungarian, Italian, Japanese, Norwegian, Polish, Portuguese, Romanian, Russian, Slovak, Slovene, Spanish, Swedish, Turkish
The applet can be used, by using a standard tag. Here the simplest one, which you can 'see' by viewing the Basic demo page:
<APPLET CODE="wjhk.jupload2.JUploadApplet" NAME="JUpload" ARCHIVE="wjhk.jupload.jar" WIDTH="640" HEIGHT="300" MAYSCRIPT="true" ALT="The java pugin must be installed."> <param name="postURL" value="yourServerScriptURL.html" /> <!-- Optionnal, see code comments --> <param name="showLogWindow" value="false" /> Java 1.5 or higher plugin required. </APPLET>
Lots of parameters can be used, to adapt the applet behavior to your needs. You'll find the full list of applet parameters available in JUpload is defined in the UploadPolicy javadoc page.
You can test the full list of applet parameters by using the Advanced demo page.
One of the 'biggest' mode you can use, is the picture mode. You can check it by going to the Picture mode demo. Here is the relevant applet tag:
<APPLET CODE="wjhk.jupload2.JUploadApplet" ARCHIVE="wjhk.jupload.jar" WIDTH="640" HEIGHT="400" alt="" MAYSCRIPT="true"> <param name="postURL" value="yourServerScriptURL.html" /> <param name="maxChunkSize" value="500000" /> <param name="uploadPolicy" value="PictureUploadPolicy" /> <!-- Optionnal, see code comments --> <param name="maxPicHeight" value="900" /> <!-- Optionnal, see code comments --> <param name="maxPicWidth" value="700" /> <!-- Optionnal, see code comments --> <param name="debugLevel" value="0" /> <!-- Optionnal, see code comments --> <param name="showLogWindow" value="false" /> Java 1.5 or higher plugin required. </APPLET>
The below code should be put before the APPLET tag, to make the navigator automtically install Java on the client computer, when opening the page. If Java is already installed on the client computer, this code makes nothing. If not, the user is asked to install it, and the installation process is automatic.
<!--"CONVERTED_APPLET"--> <!-- HTML CONVERTER --> <script language="JavaScript" type="text/javascript"><!-- var _info = navigator.userAgent; var _ns = false; var _ns6 = false; var _ie = (_info.indexOf("MSIE") > 0 && _info.indexOf("Win") > 0 && _info.indexOf("Windows 3.1") < 0); //--></script> <comment> <script language="JavaScript" type="text/javascript"><!-- var _ns = (navigator.appName.indexOf("Netscape") >= 0 && ((_info.indexOf("Win") > 0 && _info.indexOf("Win16") < 0 && java.lang.System.getProperty("os.version").indexOf("3.5") < 0) || (_info.indexOf("Sun") > 0) || (_info.indexOf("Linux") > 0) || (_info.indexOf("AIX") > 0) || (_info.indexOf("OS/2") > 0) || (_info.indexOf("IRIX") > 0))); var _ns6 = ((_ns == true) && (_info.indexOf("Mozilla/5") >= 0)); //--></script> </comment> <script language="JavaScript" type="text/javascript"><!-- if (_ie == true) document.writeln('<object classid="clsid:8AD9C840-044E-11D1-B3E9-00805F499D93" WIDTH = "0" HEIGHT = "0" NAME = "JUploadApplet" codebase="http://java.sun.com/update/1.5.0/jinstall-1_5-windows-i586.cab#Version=5,0,0,3"><noembed><xmp>'); else if (_ns == true && _ns6 == false) document.writeln('<embed ' + 'type="application/x-java-applet;version=1.5" \ CODE = "wjhk.jupload2.EmptyApplet" \ ARCHIVE = "wjhk.jupload.jar" \ NAME = "JUploadApplet" \ WIDTH = "0" \ HEIGHT = "0" \ type ="application/x-java-applet;version=1.6" \ scriptable ="false" ' + 'scriptable=false ' + 'pluginspage="http://java.sun.com/products/plugin/index.html#download"><noembed><xmp>'); //--></script> <applet CODE = "wjhk.jupload2.EmptyApplet" ARCHIVE = "wjhk.jupload.jar" WIDTH = "0" HEIGHT = "0" NAME = "JUploadApplet"></xmp> <PARAM NAME = CODE VALUE = "wjhk.jupload2.EmptyApplet" > <PARAM NAME = ARCHIVE VALUE = "wjhk.jupload.jar" > <PARAM NAME = NAME VALUE = "JUploadApplet" > <param name="type" value="application/x-java-applet;version=1.5"> <param name="scriptable" value="false"> <PARAM NAME = "type" VALUE="application/x-java-applet;version=1.6"> <PARAM NAME = "scriptable" VALUE="false"> </xmp> Java 1.5 or higher plugin required. </applet> </noembed> </embed> </object> <!-- <APPLET CODE = "wjhk.jupload2.EmptyApplet" ARCHIVE = "wjhk.jupload.jar" WIDTH = "0" HEIGHT = "0" NAME = "JUploadApplet"> <PARAM NAME = "type" VALUE="application/x-java-applet;version=1.6"> <PARAM NAME = "scriptable" VALUE="false"> </xmp> Java 1.5 or higher plugin required. </APPLET> --> <!-- "END_CONVERTED_APPLET" -->
The jupload-src-A.B.C.zip file contains the full distribution. Until 2.6.0, it contains also the compiled code (class files), but not the source (java files). This is corrected in since 2.7.0: the class files are no more there, and java files are given in the distribution jar file.
The main entry points are:
You'll find below the detail of the package content, and the main compilation results. Starting from 5.0.0, this structure is actually the standard Maven structure.
<Context path="/jupload" docBase="YourProjectPath/src/site/resources" reloadable="true"/>
The main pages/files, on this web site, are:
Once the site is built with maven command mvn site, you can use /target/site as the root for a J2EE application server, like Tomcat.