Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Silent printing + specify non-default printer

Requirements

Intranet web app needs to print jillions of receipts daily. Silent print in either Chrome or Firefox works fine --- consider this part solved.

Fly in ointment

So we use command line options in either chrome or firefox to enable speedy silent printing but these are regular workstations, not POS. They have regular network printers for everything but receipt printing.

In many configurations Firefox and Chrome will use the "last used printer", but this is unreliable and doesn't work in some configurations ...eg., Linux. Firefox does not honor changing the print command or even specifying print_printer either.

Questions

Is it possible to specify a printer on the command line:

Eg.,

firefox -no-remote -P webapp --print-target receipt

or -

chrome --kiosk --kiosk-printing receipt

Is there a plugin, extension or application that will force FF or Chrome to ignore the system default printer for a certain profile, ( or site ) and use a specified printer?

Is there a greasemonkey script to do this?

We can't rely on Firefox or Chrome to use the "last used printer" ...sometimes they do, sometimes they don't. Has anyone come up with a hackish shell script to do this ...as you can tell I'm at wits end and desperate. We would pay for this [ UPDATE: you are too late for $$ at this point, I beat you to the punch ].

like image 336
Bubnoff Avatar asked Oct 08 '22 05:10

Bubnoff


1 Answers

You can use https://github.com/edabg/jsprintsetup extension for FF.

Among the options are: setSilentPrint, setPrintersList - Returns comma separated list of available printers, setPrinter - Set current printer, getPrinter - Returns currently selected printer, etc.

like image 133
melena Avatar answered Oct 13 '22 11:10

melena