创建 Java Applet 指南,无提示打印

发布于 2024-12-20 11:14:22 字数 239 浏览 4 评论 0原文

我已经创建了一个基于网络的 POS 来接受订单。我的问题是如何创建 Java-Applet;

  1. 显示 HTML 页面 & a 打印按钮
  2. 打印订单而不提示(无对话框)

附加信息: 它的工作原理如下。服务员从电脑(POS)上敲下订单,当他们点击打印时,它会检测厨房打印机的IP地址,然后立即打印出订单,无需任何提示。我实际上正在寻找可以帮助我开始的参考/指南。任何建议也会有所帮助。谢谢

Well I have created a web-based POS to take order. My question is how do I create a Java-Applet;

  1. Shows the HTML page & a Print button
  2. Print Order without prompting(no dialogue box)

Additional Information : It works like this. The waiter will key the orders from the computer(POS) , when they hit print, it will detect the I.P address of the printer in the kitchen,then print out the orders immediately without prompt. I am actually looking for reference/guide which can help me start on. Any Advise will be helpful as well. Thank you

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

雨后咖啡店 2024-12-27 11:14:22

出于安全原因,您不能这样做。如果可以的话,当您访问不道德的网站时,小程序可能会因为打印 10 多页“特别优惠”而臭名昭著。

OTOH,如果客户端愿意在小程序启动时接受一个提示,您可以对代码进行数字签名。

You cannot do that for security reasons. If you could, applets would already have become notorious for printing 10+ pages of 'special offers' when you visit unscrupulous web sites.

OTOH, if the client is willing to accept one prompt at applet start-up, you could digitally sign the code.

长发绾君心 2024-12-27 11:14:22

有一个项目使用 HTML5 进行 HTML 打印,将内容渲染为 PNG 和 Java 以便直接打印,正如原始帖子中所述。该项目称为“qz-print”(以前称为“jzebra”),它提供自签名(免费)和可信签名(收费)的数字签名。

它还使用签名的 JNLP 文件,如 Andrew Thompson 所示。 (谢谢 Andrew,您对 Java 整体的贡献对世界各地的 Java 开发人员来说是一个很大的帮助)。

https://code.google.com/p/jzebra/

There is a project that does HTML printing using HTML5 to render the contents to a PNG and Java to print directly, exactly as described in the original post. This project is called "qz-print" (previously called "jzebra") and it offers the digital signature in both self-signed (free) and trusted-signed (at a premium).

It also uses the signed JNLP files as Andrew Thompson has illustrated. (Thanks Andrew, your contributions to Java as a whole have been a great help to Java developers around the world).

https://code.google.com/p/jzebra/

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文