html-to-pdf

Docker, Cent OS, PhantomJS Font Format Issue

℡╲_俬逩灬. 提交于 2019-12-11 17:23:55
问题 I am running a phantomJS command which converts HTML to a PDF buffer on Docker containing Cent OS. The PDF renders fine, but the font/font format is rendering The available fonts on the system are: /usr/share/fonts/lyx/eufm10.ttf: eufm10:style=LyX /usr/share/fonts/lyx/cmsy10.ttf: cmsy10:style=LyX /usr/share/fonts/lyx/msam10.ttf: msam10:style=LyX /usr/share/fonts/lyx/cmmi10.ttf: cmmi10:style=LyX /usr/share/fonts/lyx/wasy10.ttf: wasy10:style=LyX /usr/share/fonts/lyx/esint10.ttf: esint10:style

Html to pdf with images using hiqpdf

谁说我不能喝 提交于 2019-12-11 13:37:25
问题 I am converting a html with images and css files using HiQPdf 8.0 . I have done it lots of times in MVC 4 . Now I am working under MVC 5 and HiQPdf 8.0 and the problem is HiQPdf 8.0 is not loadin external files like css files and images. I solved the issue with css files by writhing the styles in a style tag in the page but do not know how to handle images. Here is my solution: byte[] pdf = RenderPdf(contractId.Value, personId.Value, addressId.Value, transportId.Value, peacockeryNumber,

html to pdf using itext xmlworker

依然范特西╮ 提交于 2019-12-11 13:26:56
问题 Document document = new Document(PageSize.A4, ml, mr, mt, mb); PdfWriter writer=PdfWriter.getInstance(document, response.getOutputStream()); String sc_na=request.getParameter("school_name"); String name=sc_na; writer.setPageEvent(new HeaderAndFooter(name)); document.open(); XMLWorkerHelper worker = XMLWorkerHelper.getInstance(); //HTMLWorker htmlWorker = new HTMLWorker(document); Class.forName("com.mysql.jdbc.Driver"); Connection con = DriverManager.getConnection("jdbc:mysql://localhost:3306

HTML to PDF using js with utf-8 support

孤街醉人 提交于 2019-12-11 08:41:18
问题 I need to export a web page as pdf it's html content that I display in the browser, I want to give the user the capability to download it as pdf, I tried jsPDF but it doesn't support arabic I need pdf not word, and I need to do it in the client side. please help Thanks in advance, 回答1: Demo: http://jsfiddle.net/kumarrishikesh12/rwdL0rxh/ <script async src="//jsfiddle.net/kumarrishikesh12/rwdL0rxh/embed/"></script> OR function doit(){ if (!window.print){ alert("You need NS4.x to use this print

No change in font face in html to pdf generation using iTextSharp

我的梦境 提交于 2019-12-11 06:58:54
问题 I'm using a HTML Rich-Text Editor to help me create a template for dynamic PDF reports, and it's working fine except that it doesn't change the font-face. This editor is using the font tag instead of CSS styles, and I would welcome any way to programmatically change the font tags to equivalent tags using styles instead. HTML (yes its messy, its from a WYSIWYG editor): <div>  <br> <div align="center"> <font size="5"> <b> <br> <div align="center"> <font font-face="Times New Roman" size="5"> <b

Html to pdf asp.net mvc [closed]

谁说我不能喝 提交于 2019-12-09 07:03:35
问题 Closed. This question is off-topic. It is not currently accepting answers. Want to improve this question? Update the question so it's on-topic for Stack Overflow. Closed 6 years ago . I am trying to find a library/tool that would allow me to generate PDF from MVC views. Any ideas, suggestions? Regards 回答1: use iTextSharp for C# which is ported from iText from JAVA check out ITextSharp HTML to PDF? 回答2: I've created a project for doing this using iTextSharp, and published on bitbucket. I

Html Div (with tags and Hindi Unicode) to PDF in asp.net c#

只愿长相守 提交于 2019-12-08 15:18:32
i want to export HTML <div> with content in Hindi (Unicode characters) to PDF in ASP.NET using C#. I've tried many different third party HTML to PDF conversion tools, such as nReco, evopdf, hiqpdf,... None of them are working properly in the sense that the Hindi text either isn't shown, or the resulting text isn't rendered correctly. For instance, if I have the text "न्‍यायालय,विरूद्व,डब्‍ल्‍यु" in Unicode, the characters are rendered incorrectly. I created an HTML file devanagari.html : <body> <div>न्‍यायालय,विरूद्व,डब्‍ल्‍यु</div> </body> And I converted this file to PDF using iText 7 + the

FOSS HTML to PDF in Python, .Net or command line?

▼魔方 西西 提交于 2019-12-08 10:13:38
问题 I have google as much as I possible, checked stackoverflow several times, and yet I can not find a good html to pdf converter that can handle css. Is there a free and open source solution (even for commercial usage)? There are many solutions, with huge variety of price ranges, but I was looking for something open source and free. I have tried PISA for Python and it works fairly well, but is not free for commercial usage. Is there anything for .Net? I have not had success with iTextSharp. 回答1:

Html Div (with tags and Hindi Unicode) to PDF in asp.net c#

你离开我真会死。 提交于 2019-12-08 05:06:30
问题 i want to export HTML <div> with content in Hindi (Unicode characters) to PDF in ASP.NET using C#. I've tried many different third party HTML to PDF conversion tools, such as nReco, evopdf, hiqpdf,... None of them are working properly in the sense that the Hindi text either isn't shown, or the resulting text isn't rendered correctly. For instance, if I have the text "न्‍यायालय,विरूद्व,डब्‍ल्‍यु" in Unicode, the characters are rendered incorrectly. 回答1: I created an HTML file devanagari.html :