What is the difference between id and class attributes?
Answers were Sorted based on User's Feedback
Answer / nashiinformaticssolutions
• id: Unique identifier for an element. Can only be used once per page. Example: <div id="main">.
• class: Used to group multiple elements with similar styling or behavior. Example: <div class="container">.
| Is This Answer Correct ? | 0 Yes | 0 No |
Answer / nashiinformaticssolutions
• id: Unique identifier for an element (used once per page).
• class: Used to define a group of elements with the same style or behavior.
| Is This Answer Correct ? | 0 Yes | 0 No |
• id: Unique identifier for an element. Can only be used once per page. Example: <div id="main">.
• class: Used to group multiple elements with similar styling or behavior. Example: <div class="container">.
| Is This Answer Correct ? | 0 Yes | 0 No |
• id: Unique identifier for an element (used once per page).
• class: Used to define a group of elements with the same style or behavior.
| Is This Answer Correct ? | 0 Yes | 0 No |
How xhtml is better than html?
How do I insert references in word 2010?
How can I copy something from a webpage to my webpage?
What is content in html?
How do you pronounce mont blanc?
What is a simple table?
What is the use of <fieldset>?
What is tag example?
How do you write a good meta title?
What is the advantage of grouping several checkboxes together?
How can I create a div work like an input?
What’s new HTML 5 DocType and Charset?