Results 1 to 1 of 1
Thread: Printing from PHP
Dec 30, 2002, 13:25 #1
- Join Date
- Dec 2002
- 0 Post(s)
- 0 Thread(s)
Printing from PHP
I have a question for all you PHP gurus. I have written the following code to test the printing functionality in PHP:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
This is a test of the print function.
$printer = printer_open();
printer_set_option($printer, PRINTER_MODE, "RAW");
When I open the Page, the printer is activated but does not print anything. I would like to know what I am doing wrong. I can use Printer_draw_text() or Printer_draw_line() and they work perfect. The "testdoc.php" is the name of the page. I tried putting in the full path name but that did not work either.
I need to set up a print button that a uset can click to print a page that is built from the contents of a database. Can any one help me with this? Thanks.