HTML Articles

Page 5 of 151

HTML DOM Meter optimum Property

AmitDiwan
AmitDiwan
Updated on 11-Mar-2026 132 Views

The HTML DOM Meter optimum property returns/sets a number corresponding to the optimum attribute of a element. Use this with high, low, min and max attributes for better results.NOTE: Don’t use as a progress bar but only as a gauge.Following is the syntax:Returning value of the optimum propertymeterElementObject.optimumValue of the optimum property setmeterElementObject.optimum = numberLet us see an example of Meter optimum property −Example Meter optimum    form {       width:70%;       margin: 0 auto;       text-align: center;    }    * {       padding: 2px;   ...

Read More

HTML DOM Time Object

AmitDiwan
AmitDiwan
Updated on 11-Mar-2026 220 Views

The HTML DOM Time Object in HTML represents the element.Creating a elementvar timeObject = document.createElement(“TIME”)Here, “timeObject” can have the following properties −PropertyDescriptiondateTimeItsets/returns the value of the dateTime attribute of a elementLet us see an example of Time dateTime property −Example Time dateTime    form {       width:70%;       margin: 0 auto;       text-align: center;    }    * {       padding: 2px;       margin:5px;    }    input[type="button"] {       border-radius: 10px;    }           ...

Read More

HTML DOM MouseEvent clientX Property

AmitDiwan
AmitDiwan
Updated on 11-Mar-2026 187 Views

The HTML DOM MouseEvent clientX property returns the horizontal (x) coordinate of the mouse pointer if a mouse event was triggered. Use with clientY to get the vertical coordinate as well.Following is the syntax −Returning reference to the clientX objectMouseEventObject.clientXLet us see an example of MouseEvent clientX property −Example MouseEvent clientX    * {       padding: 2px;       margin:5px;    }    form {       width:70%;       margin: 0 auto;       text-align: center;    }    #outer {       width:70%;       margin: 0 auto; ...

Read More

HTML DOM MouseEvent offsetX Property

AmitDiwan
AmitDiwan
Updated on 11-Mar-2026 668 Views

The HTML DO MouseEvent offsetX property returns the horizontal (x) coordinate of the mouse pointer relative to the target element if a mouse event was triggered. Use with offsetY to get the vertical coordinate as well.Following is the syntax −Returning reference to the offsetX objectMouseEventObject.offsetXLet us see an example of MouseEvent offsetX property −Example MouseEvent offsetX    * {       padding: 2px;       margin:5px;    }    form {       width:70%;       margin: 0 auto;       text-align: center;    }    #outer {       width:70%;     ...

Read More

HTML DOM TransitionEvent elapsedTime Property

AmitDiwan
AmitDiwan
Updated on 11-Mar-2026 80 Views

The HTML DOM TransitionEvent elapsedTime property returns a number corresponding to how many seconds a transition had run when a transition event is triggered.Following is the syntax −Returning number of seconds a transition has run −transitionEvent.elapsedTimeLet us see an example of TransitionEvent elapsedTime property −Example TransitionEvent elapsedTime    form {       width:70%;       margin: 0 auto;       text-align: center;    }    * {       padding: 2px;       margin:5px;    }    input[type="button"] {       border-radius: 10px;    }    #playArea {       ...

Read More

HTML DOM MouseEvent relatedTarget

AmitDiwan
AmitDiwan
Updated on 11-Mar-2026 140 Views

The HTML DOM MouseEvent relatedTarget property returns the corresponding element that triggered the respective mouseover or mouseout event.Following is the syntax −Returning reference to the relatedTarget objectMouseEventObject.relatedTargetLet us see an example of MouseEvent relatedTarget property −Example MouseEvent relatedTarget    * {       padding: 2px;       margin:5px;    }    form {       width:70%;       margin: 0 auto;       text-align: center;    }    #outer {       width:70%;       margin: 0 auto;       padding: 0;       text-align: center;     ...

Read More

HTML DOM TransitionEvent propertyName Property

AmitDiwan
AmitDiwan
Updated on 11-Mar-2026 111 Views

The HTML DOM TransitionEvent propertyName property returns a string corresponding to a CSS property used for transition when a transition event is triggered.Following is the syntax −Returning CSS property that transition has used −transitionEvent.propertyNameLet us see an example of TransitionEvent propertyName property −Example TransitionEvent propertyName    form {       width:70%;       margin: 0 auto;       text-align: center;    }    * {       padding: 2px;       margin:5px;    }    input[type="button"] {       border-radius: 10px;    }    #playArea {       display: inline-block; ...

Read More

HTML DOM Ol reversed Property

AmitDiwan
AmitDiwan
Updated on 11-Mar-2026 189 Views

The HTML DOM Ol reversed property sets/returns whether the order of list should be descending or ascending (default).Following is the syntax −Returning boolean value - true/falseolObject.reversedSetting reversed to booleanValueolObject.reversed = booleanValueHere, “booleanValue” can be the following −booleanValueDetailstrueIt defines that order willbe descendingfalseIt defines that order willbe ascending which is defaultLet us see an example of Ol reversed property −Example HTML DOM Ol reversed    form {       width:70%;       margin: 0 auto;       text-align: center;    }    * {       padding: 2px;       margin:5px;    }   ...

Read More

HTML DOM Underline Object

AmitDiwan
AmitDiwan
Updated on 11-Mar-2026 221 Views

The HTML DOM Underline Object in HTML represents the element.Creating a elementvar uObject = document.createElement(“U”)Let us see an example of Underline element −Example HTML DOM Underline    form {       width:70%;       margin: 0 auto;       text-align: center;    }    * {       padding: 2px;       margin:5px;    }    input[type="button"] {       border-radius: 10px;    }                    HTML-DOM-Underline          Warning: This is a Demo Example                        var uObject = document.getElementById("Underline");    function getBetterDisp() {       uObject.style.backgroundColor = '#DC3545';       uObject.style.color = '#FFF';    } OutputBefore clicking show button −After clicking show button −

Read More

HTML DOM Time dateTime Property

AmitDiwan
AmitDiwan
Updated on 11-Mar-2026 123 Views

The HTML DOM Time dateTime property returns/sets datetime attribute of time element.Following is the syntax −Returning string valuetimeObject.dateTimeSetting dateTime to string valuetimeObject.dateTime = YYYY-MM-DDThh:mm:ssTZDHere, “YYYY-MM-DDThh:mm:ssTZD” can be the following −stringValueDetailsYYYYIt defines year (eg:1998)MMIt defines month (eg: 05 for May)DDIt defines Day (eg: 24)TIt is a separator for date and timehhIt defines hour (eg:12)mmIt defines minutes (eg:48)ssIt defines seconds (eg:00)TZDTime Zone Designator (IST denotes Indian StandardTime)Let us see an example of Time dateTime property −Example Time dateTime    form {       width:70%;       margin: 0 auto;       text-align: center;    }   ...

Read More
Showing 41–50 of 1,508 articles
« Prev 1 3 4 5 6 7 151 Next »
Advertisements