开发者

Primefaces fileUpload working locally but not on server

I have developed an application which allows the user to upload a file.

I am using Primefaces 2.2RC2 / JSF 2.0 / Tomcat 6 / Firefox

Everything works great when I 开发者_开发百科am running it through my local server. When I push it to my live server the entire application freezes when I attempt to upload. An authentication window appears which causes it to freeze.

The upload works fine in IE which seems ridiculous.

I am not very savy when it comes to server configuration and permissions but I am assuming that this issue is probably a permissions problem.

EDIT More information

I am not storing the file locally or anything, I am just using the FileUploadEvent and then getting the contents of the file and storing it to a database like so:

public void upload(FileUploadEvent event) {
       byte[] file = event.getFile().getContents();
       ...
       myDao.uploadFile(file);
}

There are no errors in the error logs so I can't even start to track down what is going on, it just locks up.

From doing some research it looks like this Flash bug is causing the problem.

https://bugs.adobe.com/jira/browse/FP-1044

Does anyone know a work around?

On a side note: Can anyone recommend another way of uploading files using Tomcat 6, JSF 2.0 ? Using primefaces was one of the only solutions that I have found for my configuration. Thank you.


@BalusC

I you are correct in that it is a Firefox issue. Anyway what is primefaces file upload is using the SWFupload flash component. For some reason the cred's are not POSTed when the SWFupload component posts back to the page. I have not found much of a work around other than to not use SWFupload. Since primefaces does not offer another option for fileUpload I will have to wait for Primefaces 3 I guess.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜