Open spikeyfish2 opened 8 years ago
Tested the same PDF with Apache's PDFBox and everything works correctly with all viewers. I've had to resort to using a Java program to generate the PDF's via PHP, but would prefer an all-PHP solution if this could be fixed.
@spikeyfish2
At the moment, I see no chance to fix the problem. Zend_Pdf
and ZendPdf
are out of support.
Maybe @adeelnawaz or @stephenorr can help.
Hey @spikeyfish2, have you tried setting a text field in Adobe Acrobat and then viewing it in Safari or previewing it on Mac? If that works fine then the problem's with Zend_Pdf. Otherwise its general PDF issue with Mac.
@adeelnawaz Thank you very much!
Thanks @froschdesign and @adeelnawaz,
I've tested with a new PDF document created with Adobe Acrobat, and the filled in form appears correctly in Preview and Safari. I've also moved to a Java solution for now (Apache's PDFBox) which also works as expected, so I think this is an isolated issue with Zend_Pdf.
After some more investigation, it (somewhat) works correctly in Safari and Preview when no value is already specified. For example, if the form is already partially filled out with values, and the values are updated again in Zend, the values do not display correctly. But if the form is completely blank, and the values are filled in with Zend, it works correctly - although there is a graphical issue in that the text does not sit fully inside the form field, so gets clipped at the top.
I appreciate your help as I know this is now out of support.
I have created a PDF (version 1.4) with form fields, and I am updating them using:
Once I render this (either using
pdf $pdf->render()
orpdf $pdf->save('file.pdf')
) and viewing it in either Safari or Preview on mac, as well as Safari on iOS, the values haven't updated, apart from the fact that I can see them when clicking on the field itself. However, on Adobe Acrobat or Google Chrome they display correctly.