I have problem with p:fileDownload, after file is downloaded p:remoteCommand is not working :
Code: Select all
<p:remoteCommand name="nextView" update="form:tabView" process="form:tabView" oncomplete="if(!args.validationFailed ) {dosomething()}" />
<p:tabView id="tabView" onTabChange="nextView(); return false;" dynamic="true">
........
<p:commandLink ajax="false" style="float: left;" value="download font">
<p:fileDownload value="#{bean.font}" />
</p:commandLink>
I think it is a bug, but remoteCommand or fileDownload bug ?Uncaught TypeError: Cannot read property 'validationFailed' of undefined
Resource interpreted as Document but transferred with MIME type application/pdf.
it works when i remove submit param added by fileDownload before using remoteCommand:
Code: Select all
<p:tabView id="tabView" onTabChange="$('.ui-submit-param').remove();nextView(); return false;" dynamic="true">
is there any way to open new browser window when downloading file instead of sending current page ?
primefaces 3.0.M4, Glassfish 3.1.1