Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Need Readonly PDF #2

Open
johndave8116 opened this issue Apr 11, 2018 · 6 comments
Open

Need Readonly PDF #2

johndave8116 opened this issue Apr 11, 2018 · 6 comments

Comments

@johndave8116
Copy link

Hello Team,

Your code and this library is perfect and awesome - I really liked it.
But I have only one concern - once the data is merged into the PDF - I want the final PDF but not in Editable mode.
Is it possible? If Yes then please let me know how.
Really Appreciate your earliest reply.

Thank you.

@judodan
Copy link

judodan commented Oct 19, 2018

I was looking for the very same thing. Currently I am using FPDI to do this, but the problem is that when you change the form, you have to painstakingly go through the coordinates. Being able just to pass an array and have it produce an uneditable file would be great.

@mgip
Copy link

mgip commented May 27, 2020

Same problem here, some solution for that?

@imclean557
Copy link

All that's needed is a flag added to the field: /Ff 1 . See PDF Reference

There's a lot of repeated code for calculating the offset which could probably be consolidated into a single method. But for this feature, would it be enough to be able to pass a "read_only" option when merging or setting a field's value?

@imclean557
Copy link

#31

@imclean557
Copy link

Adding support in the linked PR might help move things along. Does it work for you?

@BeRightBaack
Copy link

I was able to accomplish this simply by using readonly pdf form.
Using something like https://www.pdfescape.com you can edit your form, right click on every field and in setting set it as read-only. If you use that template, values will then be added in it and will not be editable.
OFC in my case i had to run template through pdftk before I could use it with script.

Don't know your exact usage and process, but give it a try, maybe it will work for you too
s181

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

6 participants