jsf 2 - Rich faces 4.2.3 file upload not invoking backing bean method -
i trying use richfaces file upload , fileuploadlistener not invoking listener in backingbean.
code in xthml
<rich:fileupload fileuploadlistener="#{fileuploadbackingbean.uploadfile}" maxfilesquantity="#{fileuploadbackingbean.uploadsavailable}" id="uploadfls" immediateupload="#{fileuploadbackingbean.autoupload}" acceptedtypes="pdf,vnd.ms-excel,msexcel,xls" allowflash="#{fileuploadbackingbean.useflash}"> </rich:fileupload> backingbean code
@managedbean(name = "fileuploadbean") public class fileuploadbean { public void listener(fileuploadevent event) throws exception { system.out.println("listener"); } }
as shown in code, method bound file upload component "uploadfile" listener provided in fileuploadbean having name "listener". should have been, fileuploadlistener="#{fileuploadbean.listener}"
check below example, http://showcase.richfaces.org/richfaces/component-sample.jsf?demo=fileupload
Comments
Post a Comment