开发者

Socket Printing issues: PHP/Toshiba B-SA4TM

开发者 https://www.devze.com 2022-12-24 09:02 出处:网络
we\'re having this toshiba barcode printer. I\'m not sure whether this problem is hardware or php related.

we're having this toshiba barcode printer. I'm not sure whether this problem is hardware or php related.

When we send a ° (degree-sign) it prints a € (euro-sign).

I also tried brute-forcing iconv():

$a = array("UTF-8", "ASCII", "Windows-1252", "ISO-8859-15", "ISO-8859-1", "ISO-8859-6", "CP1256", "cp850");
foreach ($a as $enc){
if (@fputs($fp, iconv('UTF-8', $enc, $r)) === false) {开发者_StackOverflow ...and so on

without any success!

Is anyone familiar with this issue who can help me solve it?


Okay the problem had been two fold:

  1. The font we were using isn't capable of the degree sign
  2. The codepage of the printer had to be switched to utf-8
0

精彩评论

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