HTML to PDF / DOCX / RTF Java converter library › Forums › PD4ML v3 Archived Forums (Read Only) › General questions / FAQ › How to open pdf file in new window › Re: Re: How to open pdf file in new window
February 3, 2012 at 14:12
#28855
You can control the behavior via HTTP header:
[language=java:2wdui3qr]response.setHeader(“Content-Disposition”,”inline; filename=”doc.pdf”;”);[/language:2wdui3qr]
Forces browser to open PDF inline
[language=java:2wdui3qr]response.setHeader(“Content-Disposition”,”attachment; filename=”doc.pdf”;”);[/language:2wdui3qr]
Forces web browser to popup a Save/Open dialog.
In PD4ML JSP taglib you may control that with inline=”true/false” attribute of tag.