I copied the sourcecode in my project and it works fine, but if I try to
read the header in my servlet its nothing there.
Where is my mistake?
here is my servlet:
import java.io.IOException;
import javax.servlet.ServletException;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import org.apache.commons.fileupload.FileItem;
public class FileServiceImpl extends HttpServlet {
private static final long serialVersionUID = 1L;
private FileItem uploadedFileItem;
@Override
protected void service(final HttpServletRequest request,
HttpServletResponse response) throws ServletException, IOException {
@SuppressWarnings("rawtypes")
java.util.Enumeration e = request.getParameterNames();
java.io.PrintWriter pw = response.getWriter();
String attrib;
while (e.hasMoreElements()) {
pw.print(
(attrib = (String) e.nextElement())
+ " : "
+ request.getParameter((String) attrib)
+ "<br>"
);
}
pw.print("<br>Fertig!");
}
}
Am Mittwoch, 15. August 2012 16:42:53 UTC+2 schrieb Chak Lai:
>
> Have you try using FileUpload object from GWT?
>
>
> http://google-web-toolkit.googlecode.com/svn/javadoc/2.4/com/google/gwt/user/client/ui/FileUpload.html
>
>
>
> On Wednesday, August 15, 2012 5:13:52 AM UTC-4, Sascha Hoffmann wrote:
>>
>> Hi everybody
>>
>> I have only a little question. Is anybody here who knows a good example
>> how to upload a file with gwt oder gxt? I found two in the net but they
>> don't work. I would apreciate it if someone could help me.
>>
>> Sascha
>>
>
--
You received this message because you are subscribed to the Google Groups
"Google Web Toolkit" group.
To view this discussion on the web visit
https://groups.google.com/d/msg/google-web-toolkit/-/OTjm8L0ErD0J.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/google-web-toolkit?hl=en.