0

What are classes and id? are they the same?(IN HTML AND CSS)

I could not figure out about class es and id and there uses

27th Jun 2017, 4:56 PM
Pranay
4 ответов
+ 5
id is used by only one element, and generally used just for js to single out that one element class can b used by multiple elements and is used for styling like .bg-blue { background-color: blue; color: white; } and u could use that class for any element to b styled that way, in css class is defined as .class and id... #id
28th Jun 2017, 4:06 AM
MCJEH
MCJEH - avatar
0
*id can be applied once per page *class can be applied multiple times in a page
27th Jun 2017, 5:08 PM
‎ ‏‏‎Anonymous Guy
0
in css class elements are specified with (.) id elements are specified with (#)
27th Jun 2017, 5:13 PM
‎ ‏‏‎Anonymous Guy
0
thanks
28th Jun 2017, 4:48 AM
Pranay