Newbie printing reports
| From: | Samios | Date: | Tue, 16 Oct 2001 04:23:16 +0000 |
| Subject: | Newbie printing reports | ||
| Groups: | php.db | ||
| Request: | Send a blank email to php-db+get-13347@lists.php.net to get a copy of this message | ||
I'm building an intranet Point-of-Sale application.
Server : Linux/Apache/MySql/PHP.
Clients : Linux and NT PC's running Mozilla/Netscape (browser can be
changed).
As each sale is entered, we have to print out a report (docket) to give to
the customer - and a copy of this report for internal use.
i.e. 2 copies of the same report.
I have toyed with the Javascript print() method, but it always brings up a
print dialog box.
This really slows the process down - especially when the print dialog box
appears with each call to print().
In the past, I have used reporting tools (such as Crystal Reports) which can
send print jobs directly to the printer.
Have any other intranet/database developers faced, and solved, this problem?
I am vaguely familiar with the Linux lpr method which can send Postscript
files direct to the printer.
Using the exec() function in PHP, I was able to send a Postscript file to
the printer.
In my application, I am trying to print what appears in the users' browser,
rather than a Postscript file.
Can lpr offer a solution?
I've wasted a lot of time on this problem and am developing a migraine.
Any help would be appreciated.