What is the difference between the CLASS and ID when you are
writting CSS?
Answers were Sorted based on User's Feedback
Answer / yathindra
In CSS we can call id with '#' and can be used only one time
for one page. When coming to the case of class in CSS it can
be used infinite number of times in the same page as well as
in the whole site.
| Is This Answer Correct ? | 10 Yes | 0 No |
Answer / suji
ID uniquely identifies an element within a document where
CLASS attribute specifies an element to be a member of one
or more classes. Unlike with the ID attribute, any number of
elements can share the same class. CLASS attribute can be
used to impose a certain pattern in the webpage, like the
page's header, footer,etc. which will enhance uniformity
among all webpage of a website.
| Is This Answer Correct ? | 10 Yes | 1 No |
Answer / rojythakur.learningpp@gmail.co
# for id and . for class.
id used only one time bt not class.
| Is This Answer Correct ? | 0 Yes | 0 No |
What is the difference between html action and html renderaction?
How to create a link that will connect to another web browser page when clicked in html5?
What is definition list in html?
Why to use figcaption tag in html5?
How do you pronounce mont blanc?
Does google still use keywords?
What is the purpose of 'required' attribute in HTML5?
Who Created html?
How do you create text on a webpage that will allow you to send an email when clicked?
Explain autofocus attribute of html5?
Is it possible to set specific colors for table borders?
What are gradients in Canvas used for? What are their different types?