| Home | JSP | EJB | JDBC | Java Servlets | WAP | Free JSP Hosting | Spring Framework | Web Services | BioInformatics | Java Server Faces | Jboss 3.0 tutorial | Hibernate 3.0 | XML | ||||
|
||||
|
|
||||
| Tutorial Categories: Ajax
| Articles
| JSP
| Bioinformatics
| Database
| Free
Books |
Hibernate
| J2EE
| J2ME
| Java
| JavaScript
| JDBC
| JMS
| Linux
| MS
Technology |
PHP
| RMI
| Web-Services
| Servlets
| Struts
| UML
|
|
||||||||||||||||||||||||||||||
|
Home | JSP | EJB | JDBC | Java Servlets | WAP | Free JSP Hosting | Search Engine | News Archive | Jboss 3.0 tutorial | Free Linux CD's | Forum | Blogs |
||||||||||||||||||||||||||||||
Send your comments, Suggestions or Queries regarding this site at roseindia_net@yahoo.com.
Copyright © 2007. All rights reserved.
Current Comments
1 comments so far (post your own) View All Comments Latest 10 Comments:I got an error with follow message.
Is there anybody knows how to solve this problem?
When i upload a file smaller than 2MB, it works so well-!!
Plea~~~~~se~~~~ help me.
I wanna destroy my laptop now...
----------------------------------------
org.apache.commons.fileupload.FileUploadBase$SizeLimitExceededException: the request was rejected because its size (5096543) exceeds the configured maximum (2097152)
----------------------------------------
I attache pieces of my code.
-----------------------------------------
## Struts.xml
<interceptors>
<interceptor-stack name="authenticationStack">
<interceptor-ref name="fileUpload">
<param name="allowedTypes">
image/*
</param>
<param name="maximumSize">
1024000000
</param>
</interceptor-ref>
<interceptor-ref name="basicStack"/>
</interceptor-stack>
</interceptors>
<action name="RegisterUser" class="authentication.RegisterUser">
<interceptor-ref name="authenticationStack"></interceptor-ref>
............
## InputForm.jsp
<s:file name="photo" label="%{getText('user.photo')}" accept="image/*" />
## ActionClass.java
private File photo;// Client side file
private String photoContentType; // The content type of the file
private String photoFileName; // Server side file name
public File getPhoto() {
return photo;
}
public void setPhoto(File upload) {
this.photo = upload;
}
public String getPhotoContentType() {
return photoContentType;
}
public void setPhotoContentType(String uploadContentType) {
this.photoContentType = uploadContentType;
}
public String getPhotoFileName() {
return photoFileName;
}
public void setPhotoFileName(String uploadFileName) {
this.photoFileName = uploadFileName;
}
...........
-----------------------------------------
Thanks...
Posted by Kim on Tuesday, 08.14.07 @ 23:00pm | #23389