Screen printing process;
- Printing to HTML objects - innerHTML,
- Print to HTML page - document.write (),
- Print to alert window - alert (),
- Print to browser console - console.log ()
After the selection process, we can change the content of the selected HTML object with the innerHTML property.
Using document.write ()
If the document.write () method is used as a result of an event, all HTML elements in the number will be deleted.
Using alert ()
Using console.log ()
Note:Console Display section of your browser must be active to see the result.