Adel Amani
Adel Amani

Reputation: 21

Export HTML as PDF in JQuery for Persian

I used some free jquery libraries like jsPDF and html2pdf to export html as PDF in jquery. But non of them work properly for Persian language. How to export/convert html to PDF for Persian with Persian fonts in jquery or javascript?

please help me!

Upvotes: 0

Views: 1583

Answers (4)

Farshad
Farshad

Reputation: 1485

Try to use html2pdf library for properly export Persian/Arabic characters.

Upvotes: 0

Naim Sulejmani
Naim Sulejmani

Reputation: 1120

you can create a simple page with your report as html, and use Microsoft Print to PDF-se (Ctrl+P) to print to PDF-se and save locally

Upvotes: 1

saAction
saAction

Reputation: 2065

jsPDF can only render simple HTML to PDF

See below image, There is a tag which is not displaying properly in PDF view: enter image description here

You need to use iTextSharp in order to generate PDF from server side. it will also support Persian font.

Upvotes: 0

morovat
morovat

Reputation: 11

You can use DocRaptor. It works for Persian and other utf-8 languages. but it's not free. In free version of library, advertising bar will be added to exporting PDF.

Upvotes: 1

Related Questions