On Thu, May 13, 2004 at 09:59:56AM -0600, Ashley M. Kirchner wrote:
> 
>    Looking for a (open source) solution here: is there some way that I 
> can convert an already existing HTML page to a PDF file, by means of a 
> script (on a unix box)?

Well, http://www.babysimon.co.uk/khtml2png/ will build a PNG which you
could slurp into a PDF using libpdf in PHP.

Or, http://marginalhacks.com/Hacks/html2jpg/ may be your solution.  Or
find it on FreshMeat at http://freshmeat.net/projects/html2jpg/.

Note building PDFs that consist solely of PNG or JPG images is probably
a bad idea -- the PDFs will be heavy, and not searchable because the
text is not stored as text, it's part of the image.

Check out http://www.tdb.uu.se/~jan/html2ps.html for the most "pure" but
east pretty solution.  I've found that html2ps is way easier to set up
than the other two, but the tool is based on standards rather than a
browser's idea of what carbon-based lifeforms think is pretty.

If your goal is to take browser snapshots, then look at one of first two
tools mentioned.  If your goal is simply to convert HTML to ps/pdf, then
html2ps is the way to go.

-- 
  Paul Chvostek                                             <[EMAIL PROTECTED]>
  it.canada                                            http://www.it.ca/
  Free PHP web hosting!                            http://www.it.ca/web/

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to