hi
i wanna write a snip code that when someone send a file for printing,it can find out and before printing check its destination printer and then do somethings.
for example, suppose we have 3 printers and when a job is sent to printer1 ,our code detect it and do somethings.
how can i detect print requests?i mean, how can my code detect a job is sent (from other apps)?
working with printer
Moderator: General Moderators
Re: working with printer
You can't do it with PHP. Not without some extension that I've never heard of before and a lot of patience.
Use another language. A normal language, not something meant for server-side scripting.
Use another language. A normal language, not something meant for server-side scripting.
-
Hattori Hanzo
- Forum Newbie
- Posts: 2
- Joined: Wed Jun 10, 2009 1:52 pm
Re: working with printer
and what about JavaScript?
Re: working with printer
JavaScript is client side so it could only give the client an option to print.
Re: working with printer
You'd have to either:
- Use or create a PHP extension that can read from the print spoolers, or
- Use exec(), system(), etc to communicate with the print spoolers and grab the output
- Use or create a PHP extension that can read from the print spoolers, or
- Use exec(), system(), etc to communicate with the print spoolers and grab the output