css more than one class code example

Example 1: more than one class css

If you want two classes on one element, do it this way:
	<div class="social first"></div>

Reference it in css like so:
	.social.first {}

Example 2: css multiple classes

//HTML Code
<div class = 'firstClass secondClass'></div>

//CSS Code
.firstClass.secondClass {
  
}

Example 3: more than one class in div

<!-- You can use multiple classes per element if you simply put spaces between the names: -->

<div class="c1 c2"> This div has two classes </div>

Example 4: css multiple classes

<div class="a-class another-class"></div>

Tags:

Css Example