Previous | Home | Next |
In DHTML to allow scripts and components to access features of HTML and CSS, the contents of the document were represented as objects in a programming model known as the Document Object Model (DOM).It is the foundation of DHTML, providing a structured interface that allows you to access and manipulate virtually anything within the document.
The Dynamic HTML (DHTML) Document Object Model (DOM) allows authors direct, programmable access to the individual components of their Web documents, from individual elements to containers. This access, combined with the event model, allows the browser to react to user input, execute scripts on the fly, and display the new content without downloading additional documents from a server. The DHTML DOM puts sophisticated interactivity within easy reach of the average HTML author.
The following example, each element has a scope of influence that depends on where in the document the tags appear.
<HTML> <BODY> <DIV> <P>Some text in a <B>paragraph</B> </P> <IMG id=image1 src="mygif.gif"> </DIV> <IMG id=image2 src="mygif.gif"> </BODY> </HTML>
Previous | Home | Next |