Raible's Wiki
Raible Designs AppFuseHomepage- Korean - Chinese - Italian - Japanese QuickStart Guide User Guide Tutorials Other ApplicationsStruts ResumeSecurity Example Struts Menu
Set your name in
UserPreferences
Referenced by
JSPWiki v2.2.33
Hide Menu |
This is version 15.
It is not the current version, and thus it cannot be edited. Table of ContentsHow to Create an AJAX based fileupload progressbar dialogThis HOWTO shows how i combined AJAX Struts File Upload Progress Meter![]() ![]()
Create a struts based Appfuse projectC:\projects\appfuse-1.9.3-src\appfuse>ant new Buildfile: build.xml clean: [echo] Cleaning build and distribution directories init: new: [echo] [echo] +-------------------------------------------------------------+ [echo] | -- Welcome to the AppFuse New Application Wizard! -- | [echo] | | [echo] | To create a new application, please answer the following | [echo] | questions. | [echo] +-------------------------------------------------------------+ [input] What would you like to name your application [myapp]? progressbar [input] What would you like to name your database [mydb]? progressbar [input] What package name would you like to use [org.appfuse]? [input] What web framework would you like to use [webwork,tapestry,spring,jsf,struts]? struts [echo] Creating new application named 'progressbar'... [copy] Copying 356 files to C:\projects\appfuse-1.9.3-src\progressbar [copy] Copying 81 files to C:\projects\appfuse-1.9.3-src\progressbar\extras [copy] Copying 1 file to C:\projects\appfuse-1.9.3-src\progressbar [copy] Copying 1 file to C:\projects\appfuse-1.9.3-src\progressbar init: fixcrlf: [echo] Running fixcrlf.... [echo] [echo] +-------------------------------------------------------------+ [echo] | -- Application created successfully! -- | [echo] | | [echo] | Now you should be able to cd to your application and run: | [echo] | > ant setup test-all | [echo] +-------------------------------------------------------------+ BUILD SUCCESSFUL Total time: 38 seconds C:\projects\appfuse-1.9.3-src\appfuse> C:\projects\appfuse-1.9.3-src\appfuse>cd .. C:\projects\appfuse-1.9.3-src>cd progressbar C:\projects\appfuse-1.9.3-src\progressbar> C:\projects\appfuse-1.9.3-src\progressbar>ant setup-tomcat (if not done before. Only needed once) C:\projects\appfuse-1.9.3-src\progressbar>ant setup-db C:\projects\appfuse-1.9.3-src\progressbar>ant deploy Start tomcat and see if it works. Create a user that you can use to login and test the functionality we are going to add. Install the serverside utility classesExtract the attached fileupload.zip (see bottom of this page) to << Your project folder >>\src\web\org\appfuse\webapp\action Listing the action folder must be like: helge@duke /cygdrive/c/projects/appfuse-1.9.3-src/progressbar/src/web/org/appfuse/webapp/action $ find . . ./ActionExceptionHandler.java ./BaseAction.java ./fileupload ./fileupload/ExtendedMultiPartRequestHandler.java ./fileupload/FileUploadAction.java ./fileupload/upload ./fileupload/upload/MonitoredDiskFileItem.java ./fileupload/upload/MonitoredDiskFileItemFactory.java ./fileupload/upload/MonitoredOutputStream.java ./fileupload/upload/OutputStreamListener.java ./fileupload/upload/UploadInfo.java ./fileupload/upload/UploadListener.java ./fileupload/upload/UploadMonitor.java ./fileupload/util ./fileupload/util/UploadUtil.java ./PasswordHintAction.java ./ReloadAction.java ./SignupAction.java ./UploadAction.java ./UserAction.java helge@duke /cygdrive/c/projects/appfuse-1.9.3-src/progressbar/src/web/org/appfuse/webapp/action $ Configure DWRTest DWRCreate css and javascript filesCreate the Struts ActionCreate the Atruts JSP incliding the formAttachments:
|