Can we make print button without JavaScript?

JavascriptWeb DevelopmentFront End Technology

Yes, we can easily make a print button as well as add an image to it.


You can try to run the following code to make a print button as image i.e. whenever a user clicks on the image, the print options are visible −

Live Demo

<!DOCTYPE html>
      <a href="javascript:window.print()"><img src="" height="50" alt="print the page"></a>
      <p>Click above to print the page.<p>
Published on 03-Feb-2018 11:00:31