【发布时间】:2016-07-17 21:22:37
【问题描述】:
我已经通过以太网电缆将 EPSON TM-T81 热敏打印机连接到路由器并提供了一个 IP 地址,即 192.168.1.12 和
我有一个托管在亚马逊服务器上的网站,我想直接通过网络打印收据。
我正在使用以下库进行打印。
您可以查看下图它是如何工作的
https://github.com/mike42/escpos-php
如果我从 localhost 进行测试,我可以找到打印机并且打印工作正常,但是当我尝试从站点打印时,它会显示以下错误
<h1>Internal Server Error</h1>
<p>The server encountered an internal error or
misconfiguration and was unable to complete
your request.</p>
<p>Please contact the server administrator at
[no address given] to inform them of the time this error occurred,
and the actions you performed just before this error.</p>
<p>More information about this error may be available
in the server error log.</p>
从我的调试中我发现它找不到打印机,所以它不能生成套接字对象。
我需要在亚马逊上设置什么吗?
客户端 PC 在 Windows 8 上运行,我已经在其中安装了 epson 驱动程序。
【问题讨论】:
-
如果您尝试通过互联网连接到 192.168.1.12 - 这将不起作用,所有 192.168.xx 地址都是私有的,并且只能在同一个本地网络中路由。
标签: php amazon-web-services printing thermal-printer epson