Primefaces p:fileUpload在IE 10中不起作用 [英] Primefaces p:fileUpload doesnt work in IE 10

查看:153
本文介绍了Primefaces p:fileUpload在IE 10中不起作用的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在p:fileUpload中更新属性和onComplete在IE10中不起作用。在IE 9中sizeLimit属性被忽略。有没有人遇到这种情况。



我曾尝试通过在p:fileUoload上使用onComplete属性来调用p:remotecommand,但它看起来像onComplete在IE 10中不起作用。 b

 < h:form id =fileenctype =multipart / form-data> 
< p:outputLabel value =Test ........>< / p:outputLabel>
auto =truesizeLimit =500000
oncomplete =refreshData()
onstart =alert('test'); mode =advanced
fileUploadListener =#{fileUpload.handleFileUpload}
allowTypes =/(\。| \ /)(pdf | png)$ />

< / p:fileUpload>
< p:inputText value =#{fileUpload.test}id =test/>
< p:remoteCommand name =refreshDataaction =#{fileUpload.setData}
update =test>< / p:remoteCommand>
< / h:表格>


解决方案

最后意识到它在primefaces中的一个bug。 p>

http: //forum.primefaces.org/viewtopic.php?f=3&t=28860#p94845



http://code.google.com/p/primefaces/issues/detail?id=5355 <修正:


TargetVersion-4.0

TargetVersion- 3.5.9



Update attribute and onComplete in p:fileUpload doesnt work in IE10. In IE 9 sizeLimit attribute is ignored. Has anyone came across this situation.

I have tried calling p:remotecommand by using onComplete attribute on p:fileUoload but it looks like even onComplete doesn't work in IE 10

<h:form id="file" enctype="multipart/form-data">
        <p:outputLabel value="Test........"></p:outputLabel>
        <p:fileUpload label="Browse..." description="Select PDF file"
            auto="true" sizeLimit="500000"
            oncomplete="refreshData()"
            onstart="alert('test');" mode="advanced"
            fileUploadListener="#{fileUpload.handleFileUpload}"
            allowTypes="/(\.|\/)(pdf|png)$/">

        </p:fileUpload>
        <p:inputText value="#{fileUpload.test}" id="test" />
        <p:remoteCommand name="refreshData" action="#{fileUpload.setData}"
            update="test"></p:remoteCommand>
    </h:form>

解决方案

Finally realized that its a bug in primefaces.

http://forum.primefaces.org/viewtopic.php?f=3&t=28860#p94845

http://code.google.com/p/primefaces/issues/detail?id=5355

Fixed in:

TargetVersion-4.0
TargetVersion-3.5.9

这篇关于Primefaces p:fileUpload在IE 10中不起作用的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆