Javascript examples for Browser Object Model:Window alert
Window alert() Method - Alert box with line-breaks:
<!DOCTYPE html> <html> <body> <button onclick="myFunction()">Test</button> <script> function myFunction() {/* w ww. ja v a 2 s .c om*/ console.log("Hello\nHow are you?"); } </script> </body> </html>