printer_set_option

From: Date: Wed, 01 May 2002 23:53:49 +0000
Subject: printer_set_option
Groups: php.windows 
Request: Send a blank email to php-windows+get-13475@lists.php.net to get a copy of this message
Hi, I've been working with the printer extension lately... for work, not for fun! I'm running PHP 4.2.0, and Apache 1.3.24 on Windows 98. I've been having problems exclusively with the printer_set_option function. It doesn't seem to have any effect on the printers settings. $handle = printer_open(); printer_start_doc($handle, "My Document"); printer_start_page($handle); if ($labelSize == "mail") { printer_set_option($handle, PRINTER_PAPER_FORMAT, PRINTER_FORMAT_CUSTOM); printer_set_option($handle, PRINTER_PAPER_LENGTH, ????); printer_set_option($handle, PRINTER_PAPER_LENGTH, ???); } elseif ($labelSize == "ship") { printer_set_option($handle, PRINTER_PAPER_FORMAT, PRINTER_FORMAT_CUSTOM); printer_set_option($handle, PRINTER_PAPER_LENGTH, ????); printer_set_option($handle, PRINTER_PAPER_LENGTH, ???); } // Print stuff here... printer_end_page($handle); printer_end_doc($handle); printer_close($handle); This is basically what I'm trying to do. I know it get's into the if and elseif, then it prints using the settings that are set in the windows printer settings. Any suggestions? __________________________________________________ Do You Yahoo!? Yahoo! Health - your guide to health and wellness http://health.yahoo.com

« previous php.windows (#13475) next »