Primefaces p:fileUpload doesnt work in IE 10

前端 未结 6 1665
攒了一身酷
攒了一身酷 2021-01-13 03:07

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 ca

6条回答
  •  野趣味
    野趣味 (楼主)
    2021-01-13 03:35

    I had to face this problem with PF 5.1 migrated from PF 3 and thanks to this post i resolved:

    this is the html code generated:

    upload

    and this the CSS which resolved this problem:

    .ui-fileupload-buttonbar .ui-fileupload-choose input
    {
        position:absolute;
        top:0;
        right:0;
        margin:0;
        border:solid transparent;
        border-width:0 0 1px 1px;
        opacity:0;
        filter:alpha(opacity=0);
        -o-transform:translate(250px,  -50px) scale(1);
        direction:ltr;
        cursor:pointer;
        z-index:5000;
        width:100%;
        height: 20px;       
    }
    
    .ui-button {
        position: relative;
        overflow: hidden;
    }
    .ui-button input[type=file] {
        position: absolute;
        top: 0;
        right: 0;
        min-width: 100%;
        min-height: 100%;
        font-size: 100px;
        text-align: right;
        filter: alpha(opacity=0);
        opacity: 0;
        outline: none;
        background: white;
        cursor: inherit;
        display: block;
    }
    

提交回复
热议问题