html - Css for multiple class -


i'd know if it's possible use css multiple class same name 1 exception iterator inside :

<div class="elem-1"></div>  <div class="elem-2"></div> 

if it's possible, how should use css implement 2 classes (can lot more 2)?

you use css attribute selectors this:

[class^="elem-"], [class*=" elem-"] {   /* style properties */ } 

but rather suggest use 2 classes this

<div class="elem specialstuffclass">...</div> 

another option might use counting selectors nth-child.


Comments

Popular posts from this blog

php - trouble displaying mysqli database results in correct order -

depending on nth recurrence of job in control M -

sql server - Cannot query correctly (MSSQL - PHP - JSON) -