To print the page in Javascript you can use the following snippet.

Sample Javascript

<input type="button" value="Print Page" onclick="window.print()" />

2 thought on “How to print the page in Javascript”

Leave a Reply