escpos-php icon indicating copy to clipboard operation
escpos-php copied to clipboard

website hosted on linux but printer on windows

Open REDAL opened this issue 2 years ago • 4 comments

Hi @mike42 , can you help me please with this issue, I can print using a local webserver, but not from my hosted website? it shows me this error

Couldn't print to this printer: Failed to print. Command "smbclient '//DOMAIN-NAME/XP-80C' -c 'print -' -N -m SMB2" failed with exit code 1: Unknown parameter encountered: "princap name" Ignoring unknown parameter "princap name" gencache_init: Failed to create directory: /home/conex/.cache/samba - No such file or directory gencache_init: Failed to create directory: /home/conex/.cache/samba - No such file or directory gencache_init: Failed to create directory: /home/conex/.cache/samba - No such file or directorytree connect failed: NT_STATUS_BAD_NETWORK_NAME

my website is hosted on linux cent os , but the printer is installed on windows

help please

REDAL avatar Apr 13 '22 22:04 REDAL

Printing on local will work well with this package.

However, to print online, you will need to develop a desktop service which has to be installed on the local computer where you need printing to be done. Operating System does not matter in this case, you can be hosting on Linux based server and printing on a windows server. This desktop service interfaces between the online service and the local service.

I resolved this by developing an electron js service, which can receive commands from the online print command and then communicate those commands to the printer through USB.

mutiemule avatar Apr 30 '22 09:04 mutiemule

@mutiemule Thank you very well for your help I appreciate kindest regards

REDAL avatar May 01 '22 12:05 REDAL

@mutiemule can you share this solution with us? i have this problen too. thanks

elinardo10 avatar Aug 08 '22 04:08 elinardo10

i solve this by make an c# app that recieve printing request

Hussin22 avatar Jul 25 '23 10:07 Hussin22