1. The client fills a payment form, and submits it.
2. The server save the payment in mysql and it generates a file that needs to be printed in the client inmediately after they submit the form. (They want the file to be printed directly without prompting the window.print() dialog).
3. So I send the file to the client using an iframe (<iframe src='file.txt'>) but the problem is that I can't access the Internet temporary files folder with activex javascript.
I would do something like this if I could have access to the file.txt
Code: Select all
var wso = new ActiveXObject("WScript.Shell");
wso.Run('type file.txt > LPT1');
a. It's programmed only for internet explorer, please don't ask me why.
b. The client has an EPSON FX-1170 printer so I have to use the "type" command to send the file directly to the printer in ascii mode.
Thanks in advance for your help.