0

This has been asked before in several places, but I keep finding the question and never a solution.
If JavaScript on a page does window.print () I want to get back a status telling either
1) accomplished (which means there was some time elapsed, just like clocking does)
or
2) failed, and possibly a reason like out-of-paper or offline

That outcome could then invoke the correct follow-on page, "Printed" or "Unable to Print"
and this would also tell the server if the message had been delivered or not, in the printer tray.

The purpose is to print out orders from a web site.

Note that at least in Firefox, the USER (of a computer) can set print_silent option
to bypass the Print Dialog and [OK] button. We are using this option.

It would be nicer and safer if they could specify what domain(s) or even what page(s) are allowed to go directly to Print. Since that option is not provided, they are told to only use Firefox for this one purpose.

Please, if all you have to tell me is about it being a security issue, save it. Thanks.

2
Contributors
1
Reply
5
Views
4 Years
Discussion Span
Last Post by LastMitch
0

This has been asked before in several places, but I keep finding the question and never a solution.

Yes.

Read this

http://www.htmlgoodies.com/beyond/javascript/article.php/3471121/Print-a-Web-Page-Using-JavaScript.htm

and this:

http://stackoverflow.com/questions/6484089/printing-a-page-using-javascript

If JavaScript on a page does window.print () I want to get back a status telling either
1) accomplished (which means there was some time elapsed, just like clocking does)
or
2) failed, and possibly a reason like out-of-paper or offline

You really can't. The reason is there is alot of printers out there and there's no one code that fits all printers. Each printers has it's own setting. So that's why there's no code that fits all printers/

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.