Printing to printers in PHP
问题 I'm trying to set up a CLI PHP application to print a set of web pages to a default or specified printer. I'm on a Windows 7 machine with PHP 5.2.11 running in a CLI. To test the print functionality I've loaded PHP_printer.dll and I'm printing to Onenote, a print to file option, using the exact printer name given in PRINTER_ENUM_LOCAL. Update : Here's the latest code: $handle = printer_open("Send To OneNote 2010"); printer_start_doc($handle, "My Document"); printer_start_page($handle);