Skip to content

Enables direct printing from a web browser to a local windows machine. good sample for printing shipping labels and receipts.

License

Notifications You must be signed in to change notification settings

AsafY/Crosphera-Local-Print-Server

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Crosphera-Local-Print-Server

Enable direct printing from browser on windows machine

great for printing reciepts & shipping labels right from your javascript code.

prints any html.

you might need to add permissions to the default port:

netsh http add urlacl url=http://+:17080/ user="_DOMAIN_USER"

test if print server is up

list availbale printers

How to print:

  const printerName = "__PRINTER_NAME_";
  const data = "ANY HTML DATA TO PRINT";

  $.ajax({
            type: 'POST',
            url: 'http://127.0.0.1:17080/?op=print&printerName=' + printerName,
            crossDomain: true,
            data: data,
            dataType: 'html'
        }).done(function (responseData) {
            console.log(responseData);
        }).fail(function (responseData) {
           console.log(responseData);
        });

About

Enables direct printing from a web browser to a local windows machine. good sample for printing shipping labels and receipts.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages