Ask coding questions

← Back to all posts
print web
BsharSy

how i can print in HTML5 (cod java script print )

Voters
BsharSy
Comments
hotnewtop
SixBeeps

This question is a bit ambiguous.

If you want to "print" something using only HTML, you can't because HTML doesn't execute. HTML is not a programming language. Instead, whatever you type goes into the document directly.

If you mean in JavaScript, you have a few options.

  • If you want to print something to the console, console.log("howdy") will do that.
  • If you want to output something to the document, document.body.innerHTML += "howdy" might work.