Use document.write() to output the HTML tags : write : Document JAVASCRIPT TUTORIALS


JAVASCRIPT TUTORIALS » Document » write »

 

Use document.write() to output the HTML tags

















<html>
<head>
<title>Writing HTML</title>

</head>
<body>

<script language="javascript" type="text/javascript">
<!--

document.write("<h1>Writing HTML</h1>");

var myPara  = "<P> para </p> ";
    myPara += "<P><B>document object's write() method!</B></p>";

window.document.write(myPara);

//-->
</script>

</body>
</html>







HTML code for linking to this page:

Follow Navioo On Twitter

JAVASCRIPT TUTORIALS

 Navioo Document
» write