Answers for "make styles multiple classes"

CSS
15

css change multiple classes

.objectOne, .objectTwo { /* We will now both be changed */
	margin: 0 auto; 
}
Posted by: Guest on March-16-2020
13

css multiple classes

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

//CSS Code
.firstClass.secondClass {
  
}
Posted by: Guest on April-02-2020
0

multiple classes

//-----------used in chat App -------
var allChat = document.querySelectorAll('div[class^=chat-people]');
console.log("Found", allChat.length, "div which class starts with “chat-people”.");

intro = document.getElementById('intro-right');

for (var i = 0; i < allChat.length; i++) {
    allChat[i].addEventListener('click', function() {
    console.clear();
    console.log("You clicked:", this.innerHTML);
       });
}
Posted by: Guest on February-27-2022

Browse Popular Code Answers by Language