Last active
April 5, 2022 17:51
-
-
Save TarttWeb/f3b68165db7be5eeea1f7bd6cd7ee56b to your computer and use it in GitHub Desktop.
HTML ID & CLASS Example
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!doctype> | |
<html> | |
<head> | |
<title>Example of Element id & class attributes</title> | |
<style> | |
#main-heading { | |
font-size: 35px; | |
color: blue; | |
} | |
.my-first-paragraph { | |
color: red; | |
} | |
</style> | |
</head> | |
<body> | |
<h1 id="main-heading">This is a heading</h1> | |
<p class="my-first-paragraph">This is a paragraph.</p> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment