bestwebdesign

Freelancign web design and Graphics design

Monday, 13 November 2017

JavaScript

HTML JavaScript

 The <script> tag is utilized to characterize a customer side content (JavaScript).

The <script> element either contains scripting articulations, or it focuses to an outside content record through the src trait.

Regular uses for JavaScript are image control, shape approval, and dynamic changes of substance.

To choose a HTML element, JavaScript all the time utilize the document.getElementById(id) technique.

This JavaScript case expresses "Hi JavaScript!" into a HTML element with id="demo":

Example

<script>
document.getElementById("demo").innerHTML = "Hello JavaScript!";
</script>


JavaScript can change HTML styles

document.getElementById("demo").style.fontSize = "25px";
document.getElementById("demo").style.color = "red";
document.getElementById("demo").style.backgroundColor = "yellow";
 
Share:

0 comments:

Post a Comment


Web Design Tutorial

Theme Support

Munere veritus fierent cu sed, congue altera mea te, ex clita eripuit evertitur duo. Legendos tractatos honestatis ad mel. Legendos tractatos honestatis ad mel. , click here →