Обновить printlib.php
This commit is contained in:
parent
717813f650
commit
2cd1a94955
@ -93,7 +93,7 @@ function printean8($data) {
|
|||||||
function rawdlen($data) {
|
function rawdlen($data) {
|
||||||
$len = strlen($data);
|
$len = strlen($data);
|
||||||
$l = ($len + 3) % 256;
|
$l = ($len + 3) % 256;
|
||||||
$h = intdiv($len / 256);
|
$h = intdiv($len, 256);
|
||||||
if ($l<16) {
|
if ($l<16) {
|
||||||
$l=hex2bin("0" . dechex($l));
|
$l=hex2bin("0" . dechex($l));
|
||||||
} else {
|
} else {
|
||||||
@ -106,7 +106,7 @@ function rawdlen($data) {
|
|||||||
}
|
}
|
||||||
return $l . $h;
|
return $l . $h;
|
||||||
}
|
}
|
||||||
function printqr($data, $size) {
|
function printqr($data, $size = 16) {
|
||||||
if (strlen($data)<7088) {
|
if (strlen($data)<7088) {
|
||||||
if ($size<16) {
|
if ($size<16) {
|
||||||
$encs=hex2bin("0" . dechex($size));
|
$encs=hex2bin("0" . dechex($size));
|
||||||
|
Loading…
Reference in New Issue
Block a user