Lets's Learn Document Object Model The " DOM "document object model) allows JavaScript to access the content of a web page.The DOM is like a class monitor, where HTML elements are the like the students of a class.It monitors or keeps track of HTML documents. JavaScript is like class teacher it tell the monitor to do something. Or in other words JavaScript can manipulate HTML elements with DOM. Show Me your ID In DOM you can give unique names to HTML elements, these are called Id of the element, further this id can be used by JavaScript to manipulate or access the HTML elements.To give id to an element you can use id attribute like this ; <h1 id="Hello" >Hello</h1> ID Hello then can be then used to access the heading tag <h1> later by Javascript. Let's Catch this guy Now, when we have the name given we can catch this guy and manipulate it. To use this element we use method document.getElementById in our...
Welcome to DeeCoder here we discuss,learn and work on ideas ,languages,softwares....