Quantcast
Channel: HTML – Code Chewing
Viewing all articles
Browse latest Browse all 21

Why is there HTML comment markup for internal CSS stylesheet

$
0
0

You may have come across this:

<style type="text/css">
<!--
h1 {
  font-weight:bold;
}
-->
</style>

The HTML comments are used for older browsers that can’t interpret CSS, so they are instead commented out. For most modern browsers, the HTML comment is no longer needed for this internal CSS stylesheets. But it is good to know why they exist if you ever stumble across them.


Viewing all articles
Browse latest Browse all 21

Trending Articles