CSS Course
About Lesson

3 Type of Basic Selector
By Tag Name
Class
Id

Tag Name Selector
h1{
color:red;
font-size:15px;
}
div{

}
table{

}

Class Selector
.header{

}
<div class=“header”></div>

Id Selector
#navigation{

}
<ul id=“navigation”>
<li>Some Text</li>
<li>Some Text</li>
<li>Some Text</li>
</ul>

Class Selector Name Specification

.header{

}
.sibebar-menu{

}
.content_text{

}
.footerContent{

}

Id Selector Vs Class Selector

Id Selector
Can only use it one time on one page.

Class Selector
Can use it multiple times on one page.

Descendant Selector
#header a{

}
.list p{

}
ul#menu li{

}

Exercise Files
No Attachment Found
No Attachment Found
Join the conversation

Introducing Official ApeStaking Protocol for ApeCoin.

New Blur NFT Marketplace Courting Professional.