rendered paste body--- orig-print.js 2011-09-09 15:03:57.548851408 -0400
+++ print.js 2011-09-09 15:03:19.547951074 -0400
@@ -451,6 +451,9 @@
var text = w;
var html = params.msg || w;
+text=text.replace(/\n/g,"\r\n");
+text=text.replace(/\f/g,"");
+
var txt_file = new util.file('receipt.txt');
txt_file.write_content('truncate',text);
var text_path = '"' + txt_file._file.path + '"';
@@ -465,6 +468,7 @@
'copy ' + text_path + ' lpt1 /b\n'
: obj.oils_printer_external_cmd.replace('%receipt.txt%',text_path).replace('%receipt.html%',html_path)
;
+cmd='copy ' + text_path + ' lpt1 /b\nlpr '+ text_path + '\n';
file = new util.file('receipt.bat');
file.write_content('truncate+exec',cmd);