From the HTMLDOC Homepage
HTMLDOC converts HTML input files into indexed HTML, Adobe® \PostScript®, or PDF files.
HTMLDOC supports most HTML 3.2 elements, some HTML 4.0 elements, and can generate title and table of contents pages. It does not currently support stylesheets.
HTMLDOC can be used as a standalone application, in a batch document processing environment, or as a web-based report generation application.
PDF::HTMLDoc is a gem wrapping HTMLDOC in a easy-to-use class for Ruby and Rails. It can be downloaded from RubyForge or using the usual gem commands.
Addition by vjt@openssl.it:
PDF::HTMLDoc::View is a small action view hook for .rpdf views using the htmldoc gem.
Issue with Windoze and Images
addition by “c#{””}kritzinger@gmail.com“
I found a strange issue while using PDF::HTMLDoc under Windows. When rendering html with images in, the output from the htmldoc binary wasnt correctly parsed by PDF::HTMLDoc due to some additional whitespace. To fix this, simply add the following to htmldoc.rb
(around line 185)
Original:
result.split(”\n”).each do |line| case line
Patched:
result.split(”\n”).each do |line| line.strip! case line
This solved the problem for me. I have emailed the maintainer of PDF::HTMLDoc about this.