go to  ForumEasy.com   
CSS + jQuery
Home » Archive » Message


[Email To Friend][View in Live Context][prev topic « prev post | next post » next topic]
  ID Selector
 
Subject: ID Selector
Author: CyberSpider
In response to: Class Selector
Posted on: 04/12/2016 05:59:55 AM

While Class selector targets all elements of the same class, ID selector preceded by '#' focuses on finding a specific element with the unique identifier.

    #first {
        color: red;
        text-decoration: line-through;
    }


Try it yourself in sandbox »


 

> On 04/12/2016 05:41:22 AM CyberSpider wrote:

Class selector preceded by '.' is used to find all elements of the same class.

    .blue_underline {
        color: blue;
        text-decoration: underline;
    }


Try it yourself in sandbox »




References:

 


 
Powered by ForumEasy © 2002-2022, All Rights Reserved. | Privacy Policy | Terms of Use
 
Get your own forum today. It's easy and free.