linux: Linux version 2.6.35.6-48.fc14.i686.PAE (...) (gcc version 4.5.1 20100924 (Red Hat 4.5.1-4) (GCC) ) #1 SMP Fri Oct 22 15:27:53 UTC 2010 wkhtmltopdf: wkhtmltopdf 0.10.0 rc2 perl: This is perl 5, version 12, subversion 2 (v5.12.2) built for i386-linux-thread-multi #### #!/usr/bin/perl #### takes string containing HTML and outputs PDF to browser to download #### (otherwise would output to STDOUT) print "Content-Disposition: attachment; filename='testPDF.pdf'\n"; print "Content-type: application/octet-stream\n\n"; my $htmlToPrint = "a bunch of html"; ### open a filehandle and pipe it to wkhtmltopdf ### *the arguments "- -" tell wkhtmltopdf to get ### input from STDIN and send output to STDOUT* open(my $makePDF, "|-", "/usr/local/bin/wkhtmltopdf", "-", "-") || die("$!"); print $makePDF $htmlToPrint; ## sends my HTML to wkhtmltopdf which streams immediately to STDOUT #### Loading pages (1/6) QPainter::begin(): Returned false============================] 100% Error: Unable to write to destination