开发者

Printing to different printers using mozilla

I am currently creating a web application that will be deployed in an intranet environment. I chose firefox to be the browser that will run it.

However, in the application I am building, I need to be able to print to different printers quickly since they use different paper size depending on what client is coming. To avoid many time-wasting mistakes that could occur, for instance someone choosing the wrong printer and wasting paper. Also, the time used to find the right printer for the job and then pressing print is considered too long in the current context.

Is there any solution to this problem? I understand the potential security flaw behind this, but please be aware that this is solely an intranet project and that I can reduce the browser's security to the lowest since they don't access internet.

I know there could be 开发者_如何学Pythonsomething doable behind IE (ActiveX or VBScript) but I am using firefox. Also, I guess there could also be something rather tricky that when you press print on the browser, it saves what needs to be printed to a DB and then there is an exe app that runs and fetch that DB every set ammount of time and print to the right printer.

Any suggestion would be greatly appreciated. I doubt I am the only one to ever face this issue! :)

Thank you very much.


You need to write a Firefox extension or plugin and distribute it throughout your enterprise.


There's an alternative approach, that might even be faster, besides requiring even less setup and development.

If you are in an intranet, why not print from the server instead of the browser?

You'd have the following advantages:

  • Zero setup on the client side (except perhaps choosing a "printer set" according to the location)
  • Zero dependency on the browser setup, version, page configuration, etc
  • More flexibility (depending on the libraries you use to print, you can do things that a browser does not allow)

Of course the downside might be additional development on the server side, but that's probably easier.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜