Mirage LIVE PREVIEW

FileUpload - Basic

Simple uploader uses native browser file upload. Simple uploader is disabled at online demo.

Documentation
Single file
Choose


Multiple files; NOTE: in simple mode, you can get all files withing a single request!
Choose
<p:growl id="messages" showDetail="true" />

Single file<br />
<h:form enctype="multipart/form-data">        
    <p:fileUpload value="#{fileUploadView.file}" mode="simple" skinSimple="true"/>
    <br />
    <p:commandButton value="Submit" ajax="false" action="#{fileUploadView.upload}" disabled="true" />
</h:form>

<br />
<br />
Multiple files; NOTE: in simple mode, you can get all files withing a single request!<br />
<h:form enctype="multipart/form-data">
    <p:fileUpload value="#{fileUploadView.files}" mode="simple" skinSimple="true" multiple="true" />
    <br />
    <p:commandButton value="Submit" ajax="false" action="#{fileUploadView.uploadMultiple}" disabled="true" />
</h:form>