开发者

Disable print pdf in iframe

开发者 https://www.devze.com 2023-03-28 17:36 出处:网络
does anybody know how to disable print/save pdf file? i\'m making an application that enable user to view pdf file in开发者_开发知识库 an iframe. but i\'ve just been ordered to make it to be as \'view

does anybody know how to disable print/save pdf file? i'm making an application that enable user to view pdf file in开发者_开发知识库 an iframe. but i've just been ordered to make it to be as 'viewable but not printable'. now, what i can do is removing the toolbar button, but user still can right click and choose the print option. i had also disabling right click, but id doesn't work in iframe.

Please help.


When you create the PDF,

  • set an admin password
  • set an EMPTY user password
  • set printing document permission to false

If you do not create the PDFs or cannot edit them, then you cannot make the document view-only.


You can use the CFPDF tag to set print permissions. Create copies of all your document and batch process them (or cache them as needed).

<cfpdf action="protect" newOwnerPassword="IHaveCoolPasswords" source="cooldocument.pdf" 
    destination="protected_cooldocument.pdf" overwrite="yes" permissions="AllowScreenReaders">
0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号