为什么 primefaces Fileupload 不可见?
文件上传控件在浏览器中不可见(尽管呈现)。
当我从浏览器查看源代码时,它是这样渲染的。
<script type="text/javascript">
jQuery(function() {widget_exeupload1 = new PrimeFaces.widget.Uploader('exeupload1', {uploader:'/jsfscrb/javax.faces.resource/fileupload/uploadify.swf.xhtml?ln=primefaces&v=2.2.1',script:'/jsfscrb/home.xhtml',cancelImg:'/jsfscrb/javax.faces.resource/fileupload/cancel.png.xhtml?ln=primefaces&v=2.2.1',formId:'j_idt225',fileDataName:'exeupload1_file',multi:false,auto:true,inputFileId:'exeupload1_file',jsessionid:'f99f510153df31f57a310fb8de8e',update:'dlist1 resmsg',fileDesc:'Resource Files'});});
</script>
我使用 Fedora Core 3、NetBeans 6.8、Mojarra 2.0.4 和 glassfish 服务器 v3。在 Firefox 2.0.0.20 和 Opera 10.11 中观察到了上述行为。
我想知道问题可能出在哪里,老实说无法猜到。非常欢迎为识别和/或解决问题提供的每一个小帮助!
问题可能出在哪里?
- FedoraCore 3 图形包
- Primefaces
- Firefox 或 Opera
The fileupload Control for is not visible in the browser(rendered though).
When I viewed the source code from the browser, it was rendered like this..
<script type="text/javascript">
jQuery(function() {widget_exeupload1 = new PrimeFaces.widget.Uploader('exeupload1', {uploader:'/jsfscrb/javax.faces.resource/fileupload/uploadify.swf.xhtml?ln=primefaces&v=2.2.1',script:'/jsfscrb/home.xhtml',cancelImg:'/jsfscrb/javax.faces.resource/fileupload/cancel.png.xhtml?ln=primefaces&v=2.2.1',formId:'j_idt225',fileDataName:'exeupload1_file',multi:false,auto:true,inputFileId:'exeupload1_file',jsessionid:'f99f510153df31f57a310fb8de8e',update:'dlist1 resmsg',fileDesc:'Resource Files'});});
</script>
I use the Fedora Core 3, NetBeans 6.8, Mojarra 2.0.4 with glassfish server v3. Above said behavior was observed with Firefox 2.0.0.20 and also with Opera 10.11.
I am wondering where might the problem be and honestly couldn't guess it. Every little help to identify and/or solve the problem is very welcome please!!!
Where could the problem be?
- FedoraCore 3 graphic packages
- Primefaces
- Firefox or Opera
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
PrimeFaces 2.2.x 文件上传使用 flash,因此根据 flash 插件,它可能会出现问题。尝试 3.0 的新文件上传,它使用 HTML5 并进行优雅的降级。 3.0 不需要闪光灯。
http://www.primefaces.org/showcase/ui/file/upload /basic.xhtml
PrimeFaces 2.2.x fileupload uses flash so depending on flash plugin, it might have issues. Try 3.0's new fileupload which uses HTML5 with graceful degradation. No flash is required with 3.0.
http://www.primefaces.org/showcase/ui/file/upload/basic.xhtml