Computing Scotland

JavaScript Interactive Property Editor

Example 1: JavaScript Body Background Color:

document.getElementById("mainBody").style.backgroundColor = ;

Example 2: JavaScript Div Background Color:

document.getElementById("DIVexample2").style.backgroundColor = ;

Example 3.1: JavaScript Font Color:

document.getElementById("DIVexample3").style.color = ;

Example 3.2: JavaScript Font Size:

document.getElementById("DIVexample3").style.fontSize = px ;

Example 4: JavaScript Img Size:

document.getElementById("image").style.width = ;

document.getElementById("image").style.height = ;