What is a DHTML file?
DHTML File Format
DHTML files are plain text files that contain DHTML code to implement the dynamic behaviour of the web elements.
The DHTML Document object Model (DOM) is based on the HTML DOM that is a tree-structure with elements, attributes and text as shown in the following image.
This code writes the text “Hello World” to output in browser.
|1||onabort||It occurs when the user aborts the page or media file loading.|
|2||onblur||It occurs when the user leaves an HTML object.|
|3||onchange||It occurs when the user changes or updates the value of an object.|
|4||onclick||It occurs or triggers when any user clicks on an HTML element.|
|5||ondblclick||It occurs when the user clicks on an HTML element two times together.|
|6||onfocus||It occurs when the user focuses on an HTML element. This event handler works opposite to onblur.|
|7||onkeydown||It triggers when a user is pressing a key on a keyboard device. This event handler works for all the keys.|
|8||onkeypress||It triggers when the users press a key on a keyboard. This event handler is not triggered for all the keys.|
|9||onkeyup||It occurs when a user released a key from a keyboard after pressing on an object or element.|
|10||onload||It occurs when an object is completely loaded.|
|11||onmousedown||It occurs when a user presses the button of a mouse over an HTML element.|
|12||onmousemove||It occurs when a user moves the cursor on an HTML object.|
|13||onmouseover||It occurs when a user moves the cursor over an HTML object.|
|14||onmouseout||It occurs or triggers when the mouse pointer is moved out of an HTML element.|
|15||onmouseup||It occurs or triggers when the mouse button is released over an HTML element.|
|16||onreset||It is used by the user to reset the form.|
|17||onselect||It occurs after selecting the content or text on a web page.|
|18||onsubmit||It is triggered when the user clicks a button after the submission of a form.|
|19||onunload||It is triggered when the user closes a web page.|