1.

How To Upload Struts File In Dhtml?

Answer»

The interface org.apache.struts.UPLOAD.FormFile is used for the struts file upload APPLICATION. This interface represents a file that has been uploaded by a client. It is the only interface or CLASS in upload package which is typically referenced directly by a Struts application.

This is not SPECIFIC to Struts in case of DHTML but the two things that are needed in DHTML page is: first, the form needs to specify an enctype of multipart/form-data and second an <input&GT; form control of type file.

Following are the steps to load file in DHTML:

1. Creating a bean
2. Writing the ActionClass
3. Mapping the bean in struts-config.xml
4. Defining actionmapping
5. Developing the DHTML page

The interface org.apache.struts.upload.FormFile is used for the struts file upload application. This interface represents a file that has been uploaded by a client. It is the only interface or class in upload package which is typically referenced directly by a Struts application.

This is not specific to Struts in case of DHTML but the two things that are needed in DHTML page is: first, the form needs to specify an enctype of multipart/form-data and second an <input> form control of type file.

Following are the steps to load file in DHTML:

1. Creating a bean
2. Writing the ActionClass
3. Mapping the bean in struts-config.xml
4. Defining actionmapping
5. Developing the DHTML page



Discussion

No Comment Found