Multiline comments : Comments « Language Basics « JavaScript Tutorial






/* */ enables comments to span multiple lines.

<html>
<head>
<title>A Simple Page</title>
<script language="javascript">
<!--
/*
Below two alert() methods are used to
fire up two message boxes - note how the
second one fires after the OK button on the
first has been clicked
*/
alert("An alert triggered by JavaScript!");
alert("A second message appears!");
//  -->
</script>
</head>
<body>

</body>
</html>








1.1.Comments
1.1.1.Single line comments
1.1.2.Multiline comments
1.1.3.Hide scripts using comments