Computer Hope

Microsoft => Microsoft DOS => Topic started by: smaftei on November 04, 2010, 12:27:57 PM

Title: lpr command
Post by: smaftei on November 04, 2010, 12:27:57 PM
Hello,

I do not have very much knowledge about DOS, but I have been reading. I am trying to use the lpr command to print a pdf document, but is there a way I could incorporate the lpr command in my webpage so when the user clicks print it will execute that command? Or do you have a better recommendation to use the lpr command with a more user friendly than command prompt?
Title: Re: lpr command
Post by: Geek-9pm on November 04, 2010, 01:56:41 PM
Do you want a visitor to go to a web page and print that page?
If so, you can not just use a DOS command. You don't know what OS he has. Maybe he is using an Apple, not DOS.
In JavaScript you can print a page.
Print a Web Page Using JavaScript (http://www.htmlgoodies.com/beyond/javascript/article.php/3471121/Print-a-Web-Page-Using-JavaScript.htm)
Of course, that is not for a PDF file.