Closed maxpoland closed 6 years ago
At a first glance, this seems to be an error in the tool that generated your form. But I can't say for sure.
@vog thanks for your reply. I tried it with 2 files. I used Template PDF from MCPDF itself, which shows me Russian chars correctly. but after I flatten it hides everything in form fields, even the English chars as well.
maybe you can send me sample with code please ?
I don't know what you mean with "code". All code is here in the GitHub repository.
I remember that we had a broken PDF template in the past, where also text disappeared that was entered into the form. Back then, our only solution was to generate the PDF form with a different program (LibreOffice is quite good at that).
Hope that helps.
By code I mean, if you have working fully example with php code and pdf file. If you can send that would be great.
thanks
I still don't understand. Mcpdf is a Java command-line tool. There's no PHP code involved at all.
yes it is, but it can be used in php, I am doing is very successfully, only problem I have is flatten issue which I shared.
Okay, to keep this short:
I propose that you create a very small PDF form, maybe just a single text field, with LibreOffice or some other tool. Then, try to fill in values for that. If that still fails, please post it here, so we have a starting point for further investigation.
I have similar problem with russian chars Sample XFDF `<?xml version="1.0" encoding="UTF-8"?> <xfdf xmlns="http://ns.adobe.com/xfdf/" xml:space="preserve"
<f href="download.pdf" /><field name="005_ben_name_1" <value Русский tester Łódź ♠п</value </field <ids original="9C5B7A38694F2604E71F8BCCF033B640" modified="FA344A4E20B41E4796AC8A0EAF1671D5" /></xfdf `
As result I receive wrong text in PDF
tester Łód
I use command
java -jar mcpdf.jar download.pdf fill_form - output - flatten < two.xfdf > OUTPUT.pdf
ps solved, problem was with Helvetica font. With Arial and Times New Roman it works
@zip1798 I'm glad you were able to solve your issue.
After form fill I see empty pdf, when I click on a field, it shows me correct chars.
after flatten I see nothing in filled fields.
please suggest.