nowadays i am ordered to make a fileUpload component which could invoke under jsf application. According to the RFC 1867 to upload file through HTTP, the form post to sever should ENCTYPE="multipart/form-data", so i write code like this:
<f:view>
<h:form ENCTYPE="multipart/form-data" >
<input type="file" name="choose file"/>
<h:commandButton value="upload" actionListener="#{uploadBean.upload}">
</h:form>
</f:view>
but it doesn't work, plz anyone show me the answer,thanks!!