m-click / mcpdf

Mcpdf is an alternative to PDFtk with fixed unicode issues, so you can write Łódź into your forms.
GNU Affero General Public License v3.0
44 stars 10 forks source link

Russian char #22

Closed maxpoland closed 6 years ago

maxpoland commented 8 years ago

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.

vog commented 8 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.

maxpoland commented 8 years ago

@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.

maxpoland commented 8 years ago

maybe you can send me sample with code please ?

vog commented 8 years ago

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.

maxpoland commented 8 years ago

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

vog commented 8 years ago

I still don't understand. Mcpdf is a Java command-line tool. There's no PHP code involved at all.

maxpoland commented 8 years ago

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.

vog commented 8 years ago

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.

zip1798 commented 6 years ago

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

vog commented 6 years ago

@zip1798 I'm glad you were able to solve your issue.