As far as I understand you want a solution for server-side printing, right?
If it is a network-enabled printer that's connected to the server that serves the web page, you could use the lp
Linux command. On Windows you can use the lpr
command.
The file to print could be generated from the web page code with wkhtmltopdf or mpdf.
If it's not on the same network, you could set up a script on the printer network that checks an email address and sends the attachments from specific emails to the printer.