Has anyone considered adding htmldoc to the list of compatible PDF generators? Neither dompdf nor tcpdf work well for me (I eventually got dompdf to work by installing the free version of the pdflib library, but the watermark is annoying, and it screws up the images a bit). I am on a hosted server, so I have assumed (as per the documentation) that wkhtmltopdf is not practical.
The free version of htmldoc seems to do a nice job on the print-web pages I have tested it on, with minimal configuration required (it seems to need the embedded jscript to be removed, but I don't understand why the print-web version of the pages needs the jscript anyway, and it's easily removed from the print.tpl.php file). I have a feeling it shouldn't take much to incorporate (http://www.htmldoc.org/documentation.php/CallingHTMLDOCfromPHP.html), but I'm not much of a PHP/drupal coder. The only wrinkle I've noticed is that it doesn't include the images if passed the html (even though the html includes the base href), whereas it does include them if passed the URL.
One advantage over tcpdf and dompdf is that htmldoc seems to be available in the standard debian/ubuntu and mandriva repositories (and probably others), whereas the other two don't seem to be. It is available for Windows and Mac as well. And it has a relatively small number of dependencies (compared to webkit). One would think that all it would require would be to allow it as an option on the configuration page, incorporate a function to call it (as per the instructions at the above URL), and instruct people to run apt-get, urpmi or whatever to install the program. But as I say, I'm not much of a drupal coder, so I may not have understood what it takes.
Comments
Comment #1
jcnventurahtmldoc will be as pratical as wkhtmltopdf. By this I mean that you'll probably need to compile it and install it in your hosted server, if it is not already there.
However, it might be an interesting option, I will look into it when I have the time.
Comment #2
sylvaticus commentedJust to support htmldoc, it is in the FreeBSD repositories while wkhtmltopdf is not (and, of course, we are "sysadmined" by FreeBSD guys.. :-) )
Comment #3
johnpitcairn commentedSubscribe. This looks like a good option for those of us who have admin access to the server but don't want to run X11 (for security). I might have time soon to take a look at this and submit patches if I get something working.
Comment #4
jcnventuraYou can take a look at #826820: PrinceXML: PDF Library supporting floating images and much more for a similar patch.
Comment #5
jcnventuraMoved these requests into a catch-all issue: #1591718: Add support for other PDF libraries