“couleur d'arrière-plan de style javascript” Réponses codées

couleur d'arrière-plan de style javascript

 // change background color for specific id ..
function changebackground(){
	document.getElementById('id').style.backgroundColor = 'green' ; 
}
// change background color for whole body..
function changebackground(){
	document.body.style.backgroundColor = 'green';
}
 
dr3am_warri0r

JavaScript Change Couleur d'arrière-plan

document.body.style.backgroundColor = "yellow";
Black Bat

JavaScript Change Couleur d'arrière-plan

function changeBackground(color) {
   document.body.style.background = color;
}

window.addEventListener("load",function() { changeBackground('red') });
Mobile Star

Comment changer la couleur d'arrière-plan en utilisant JS

var warning = document.getElementById("warning");
  warning.style.background-color = "red";

rabbit.sol

Comment changer la couleur d'arrière-plan de HTML dans JavaScript

document.querySelector('html').style.backgroundColor = 'red';
shahsawood

document.body.style.background

// Change the background color to red
document.body.style.backgroundColor = "red"; 
Inquisitive Iguana

Réponses similaires à “couleur d'arrière-plan de style javascript”

Questions similaires à “couleur d'arrière-plan de style javascript”

Parcourir les réponses de code populaires par langue

Parcourir d'autres langages de code