CSS Comments

Unique beauty

 CSS Comments: 

 To comment in CSS, simply place your plain text inside /* */ marks. This tells the browser that they are notes and should not be rendered on the front end.

➡A CSS comment is placed inside the <style> element, and starts with /* and ends with */ :

/* This is a single-line comment */ p { color: red; } Try it Yourself »

p { color: red; /* Set text color to red */ } Try it Yourself »

/* This is. a multi-line. comment */ p { color: red; } Try it Yourself

Syntax:

<!DOCTYPE html>

<html>

<head>

<style>

/* This is a single-line comment */

p {

  color: bule;

</style>

</head>

<body>

<p>Hello Gocources!</p>

<p>This website is helpful </p>

<p>Gocources is online site</p>

</body>

</html>

Output:

Hello Gocources !

This website is helpful

Gocources is online site 


Our website uses cookies to enhance your experience. Learn More
Accept !

GocourseAI

close
send