Flying saucer Implement HTML to PDF (and some issues, continuous update)A detailed introduction is available on the Flyingsaucer website.Website address: https://today.java.net/pub/a/today/2007/06/26/generating-pdfs-with-flying-saucer-and-itext.html# The-problem-with-pdfsThe Chinese have the following problems in using Flyingsaucer to convert HTML into PDF:L Chin
Http://code.google.com/p/wkhtmltopdf/
Description
Simple shell utility to convert HTML to PDF using the WebKit rendering engine, and QT.Introduction
Searching the web, I have found several command line tools that allow you to convert a HTML-document to a PDF-document, however they all seem to use their own, and rath
Like what:Aspose.total for. NET includes the following components:Aspose.words for. NET 16.3.0 (4/13/2016)-View Release NotesAspose.cells for. NET 8.8.0 (4/21/2016)-View Release NotesAspose.pdf for. NET 11.5.0 (4/7/2016)-View Release NotesAspose.slides for. NET 16.3.0 (4/11/2016)-View Release NotesAspose.email for. NET 6.4.0 (4/11/2016)-View Release NotesAspose.barcode for. NET 7.8.0 (3/29/2016)-View Release NotesAspose.imaging for. NET 3.5.0 (4/11/2016)-View Release NotesAspose.tasks for. NET 9
The example of this article describes the use of Html2fpdf and Wkhtmltoimage in Linux to directly generate the HTML Web page PDF format File method, share for everyone to reference. The implementation methods are as follows:
Find a fpdf and Html2fpdf source based on the development of a set of open source programs, the author is very strong. The basic solution of the Chinese (as well as Japanese, Korean an
Premise:
Install Xhtml2pdf https://pypi.python.org/pypi/xhtml2pdf/Download font: Microsoft James Black; Address: http://www.jb51.net/fonts/8481.html
Files to convert: 1.htm
Copy Code code as follows:
html_to_pdf.py Program
Copy Code code as follows:
#-*-Coding:utf-8-*-
Import SX.PISA3 as Pisa
Data= open (' 1.htm '). Read ()
result = File (' test.pdf ', ' WB ')
PDF
This article introduces how to use HTML2FPDF and wkhtmltoimage in linux to directly generate pdf files on Webpage html. I hope this method will be helpful to you.
Finally, I found an open-source program developed based on the FPDF and HTML2FPDF source code. It basically solves the problem of garbled characters in Chinese (as well as Japanese, Korean, and Southeast Asia and global languages). It is available
The example in this article describes the Java implementation of HTML-pdf-conversion methods. Share to everyone for your reference. as follows:
Package test;
Import Java.io.File;
Import Java.io.FileOutputStream;
Import Java.io.OutputStream;
Import Org.xhtmlrenderer.pdf.ITextFontResolver;
Import Org.xhtmlrenderer.pdf.ITextRenderer;
Import Com.lowagie.text.pdf.BaseFont; public class Wordtopdf {/** * @p
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.