Non-fiscal thermal printer EPSON does not work in a shared way with USB and LPT

0

I'm creating a system in PHP and we're entering the printing phase with non-fiscal thermal printers. In principle I did not find Epson support for PHP printing and in searches I found the component mike42 / escpos-php . Using it I got networked impressions with Ethernet and local with USB. My client needs networked LPT printing and also networked USB.

The system will run on tablet's and there will be a print server where does not necessarily have to be in PHP because it uses REST with print data passed via JSON to it.

My need is to create a server where you can print other computers that have printers shared with it, but the printers are USB and / or LPT .

Note: In the mike42 / escpos-php component description it is supported but in practice it was not possible because the following message appears: Warning: copy (\ NAME-SERVER \ printer_name): failed to open stream: Permission denied in ... \ escpos-php-1.5. 1 \ src \ Mike42 \ Escpos \ PrintConnectors \ WindowsPrintConnector.php on line 372 .

Any suggestions, has anyone ever come across a similar situation?

On file permissions issues, when giving permissions in the PRINTERS folder of both the server and the computer where the printer is installed and shared with the server the message remains, where according to searches the same should disappear. Adding this fact and being at the very beginning of the impressions part, so it would not be a problem if the server was in another language, for example.

Thanks for the answers but so far unsuccessful.

    
asked by anonymous 10.06.2017 / 01:11

2 answers

1

Viewing line 372 from the WindowsPrintConnector.php file:

return copy($from, $to);

We see that you are trying to make a copy of a file from one location to another. Verify that you are allowed to create a file in the destination path folder specified in the $to variable and that the file path specified in $from is valid.

    
10.06.2017 / 15:43
1

On the issue of error Permission denied I believe you can solve with the security options and users.

Edit

Try this: Printer Properties > Security > Add > Advanced ... > Find Now > Select user "NETWORK SERVICE" > OK > OK > Mark printing options and manage documents > OK. Take a test.

When you talk about LPT ports, any printer that is in the windows spooler, you can share and direct the LPT port to this share.

Ex: Epson X printer, share name \ server \ epsonx

run the command: net use LPT1 \ Server \ epsonx

From there, all prints sent to the LPT1 port will be forwarded to the epson server.

    
10.06.2017 / 05:14