×

Html & Html5

The World's best Software Development Study Portal

CSS Comments


Generally comments are meant for the ease of reading the code for the code readers and these comments are ignore by the browser.It is just for the user.
For Example:-

<!DOCTYPE html>

<html>

<head>

<style>

/* This is a single-line comment */ (only using in vscode editor)

<!-- using in notepad++ editor-->

p {

      text-align: center;

      color: blue;

}

/* This is

a multi-line

comment */ (only using in vscode editor)

</style>

</head>

<body>

<p> Comments are helpful for the code readers.</p>

</body>

</html>


Output of the program



Comments are helpful for the code readers.


So this is how comments are implemented in a code and there is no effect in giving the output.






CSS 3 training insitute | Best IT Training classes in Gurgaon | Web Designing Training Institute