Printing a webpage
Wednesday, December 6th, 2006Webpage can be printed using window.print(). Here is the code:
<a onclick="window.print(); return false" href="http://ash-mvc.org/blog/webpage.html">Print This Page</a>
“return false” cancels the link to “webpage.html”.
When the hyperlink “Print This Page” is clicked, the page is printed if the printer is already installed.
JavaScript print function




