rt1338133 / hello-world

just another repository
0 stars 0 forks source link

Mike42 not printing to lp1 #1

Open rt1338133 opened 7 years ago

rt1338133 commented 7 years ago

I can echo "Hello" >> /dev/usb/lp1 just fine, but when I try to run the Mike42 PHP examples on localhost, I get error on FilePrintConector Couldn't print to this printer: The log gives the following error:

[Mon Aug 14 23:12:54.860676 2017] [:error] [pid 4121] [client 127.0.0.1:37132] PHP Warning: fopen(/dev/usb/lp1): failed to open stream: Permission denied in /var/www/html/vendor/mike42/escpos-php/src/Mike42/Escpos/PrintConnectors/FilePrintConnector.php on line 35

rt1338133 commented 7 years ago

Any help would be greatly appriciated. I did chown -R root:[username] on the vendor directory. lp1 is chown root:lp lp1