Found 2202 Articles for HTML

HTML DOM localStorage Properties

AmitDiwan
Updated on 15-Feb-2021 04:38:59

238 Views

The HTML DOM localStorage Properties enables user to store key-value pairs in local browser itself for future reference. Key-value pairs are not lost until explicitly removed/cleared.SyntaxFollowing is the syntax −Window.localStorageHere, localStorage can have following properties/methods −setItem(‘key’, ’value’)getItem(‘key’)removeItem(‘key’)Let us see an example of localStorage properties −Example Live Demo LocalStorage clear()    form {       width:70%;       margin: 0 auto;       text-align: center;    }    * {       padding: 2px;       margin:5px;    }    input[type="button"] {       border-radius: 10px;    }    table, th, td { ... Read More

HTML DOM Window frames Property

AmitDiwan
Updated on 21-Dec-2021 07:57:17

239 Views

The HTML DOM Window frames property returns an object corresponding to the window, representing all frames present in it.SyntaxFollowing is the syntax −Returning frames in current windowwindow.framesLet us see an example of HTML DOM Window frames property −Example HTML DOM Window frames    * {       padding: 2px;       margin:5px;    }    form {       width:70%;       margin: 0 auto;       text-align: center;    }    input[type="button"] {       border-radius: 10px;                    HTML-DOM-Window-frames   ... Read More

HTML DOM Window frameElement Property

AmitDiwan
Updated on 21-Dec-2021 08:01:37

284 Views

The HTML DOM Window frameElement property returns a HTML element corresponding to the window in which it is embedded such as , , or .SyntaxFollowing is the syntax −Returning window embedding elementwindow.frameElementExampleLet us see an example of HTML DOM Window frameElement property − HTML DOM Window frameElement    * {       padding: 2px;       margin:5px;    }    form {       width:70%;       margin: 0 auto;       text-align: center;    }    input[type="button"] {       border-radius: 10px;           ... Read More

HTML DOM Window closed Property

AmitDiwan
Updated on 21-Dec-2021 08:03:26

174 Views

The HTML DOM Window closed property returns a boolean value corresponding to the state of a window is closed or not.SyntaxFollowing is the syntax −Returning boolean valuewindow.closedExampleLet us see an example of HTML DOM Window closed property − HTML DOM Window closed    * {       padding: 2px;       margin:5px;    }    form {       width:70%;       margin: 0 auto;       text-align: center;    }    input[type="button"] {       border-radius: 10px;                   ... Read More

HTML DOM WheelEvent deltaY Property

AmitDiwan
Updated on 21-Dec-2021 08:43:57

252 Views

The HTML DOM WheelEvent deltaY property returns a signed number corresponding to whether user is scrolling up or down, if user is scrolling in any other direction this property returns 0.SyntaxFollowing is the syntax −Returning signed numberevent.deltaYExampleLet us see an example of HTML DOM WheelEvent deltaY property − HTML DOM WheelEvent deltaY    * {       padding: 2px;       margin:5px;    }    form {       width:70%;       margin: 0 auto;       text-align: center;    }    input[type="button"] {       border-radius: 10px;    }   ... Read More

HTML DOM WheelEvent deltaX Property

AmitDiwan
Updated on 21-Dec-2021 08:47:05

153 Views

The HTML DOM WheelEvent deltaX property returns a signed number corresponding to whether user is scrolling left or right, if user is scrolling in any other direction this property returns 0.SyntaxFollowing is the syntax −Returning signed numberevent.deltaXLet us see an example of HTML DOM WheelEvent deltaX property −Example HTML DOM WheelEvent deltaX    * {       padding: 2px;       margin:5px;    }    form {       width:70%;       margin: 0 auto;       text-align: center;    }    input[type="button"] {       border-radius: 10px;    }   ... Read More

HTML DOM Video width Property

AmitDiwan
Updated on 15-Feb-2021 04:46:52

131 Views

The HTML DOM Video width property returns/sets a number corresponding to width (in pixels) of media.SyntaxFollowing is the syntax −Returning width as a number (px)mediaObject.widthSetting width to a number (px)mediaObject.width = numberLet us see an example of Video width property −Example Live Demo HTML DOM Video width    * {       padding: 2px;       margin:5px;    }    form {       width:70%;       margin: 0 auto;       text-align: center;    }    input[type="button"] {       border-radius: 10px;    }         ... Read More

HTML DOM Video volume Property

AmitDiwan
Updated on 15-Feb-2021 04:49:31

102 Views

The HTML DOM Video volume property returns/sets a number corresponding to current volume level of media.SyntaxFollowing is the syntax −Returning volume as a numbermediaObject.volumeSetting volume to a numbermediaObject.volume = numberNOTE: Number has a max value of ’1.0’ and if ‘0.0’ video volume is min.Let us see an example of Video volume property −Example Live Demo HTML DOM Video volume    * {       padding: 2px;       margin:5px;    }    form {       width:70%;       margin: 0 auto;       text-align: center;    }    input[type="button"] {     ... Read More

HTML DOM Video textTracks Property

AmitDiwan
Updated on 15-Feb-2021 04:52:12

70 Views

The HTML DOM Video textTracks property returns a TextTrackList object containing information about the text tracks for the video.SyntaxFollowing is the syntax −Returning TextTracksList ObjectmediaObject.textTracksLet us see an example of Video textTracks property −Example Live Demo HTML DOM Video textTracks    * {       padding: 2px;       margin:5px;    }    form {       width:70%;       margin: 0 auto;       text-align: center;    }    input[type="button"] {       border-radius: 10px;    }                    HTML-DOM-Video-textTracks ... Read More

HTML DOM Video src Property

AmitDiwan
Updated on 15-Feb-2021 04:54:54

111 Views

The HTML DOM Video src property returns/sets a string corresponding to the url of the video.SyntaxFollowing is the syntax −Returning string valuemediaObject.srcSetting src to a URLStringmediaObject.poster = URLStringLet us see an example of HTML DOM Video src property −Example Live Demo HTML DOM Video src    * {       padding: 2px;       margin:5px;    }    form {       width:70%;       margin: 0 auto;       text-align: center;    }    input[type="button"] {       border-radius: 10px;    }               ... Read More

Advertisements