Article Categories
- All Categories
-
Data Structure
-
Networking
-
RDBMS
-
Operating System
-
Java
-
MS Excel
-
iOS
-
HTML
-
CSS
-
Android
-
Python
-
C Programming
-
C++
-
C#
-
MongoDB
-
MySQL
-
Javascript
-
PHP
-
Economics & Finance
Front End Technology Articles
Page 60 of 652
HTML DOM Track label Property
The HTML DOM Track label property sets or returns the value of the label attribute of a element. This property specifies the visible text that describes the track content, such as "English Subtitles" or "Audio Description". Syntax Following is the syntax for returning the label value − trackObject.label Following is the syntax for setting the label value − trackObject.label = labelValue Parameters labelValue − A string that specifies the user-readable title for the track. This value appears in the browser's track selection menu. Return Value Returns ...
Read MoreHTML DOM Track src Property
The HTML DOM Track src property sets or returns the value of the src attribute of a element. This property specifies the URL of the track file that contains subtitles, captions, descriptions, chapters, or metadata for a video or audio element. Syntax Following is the syntax for getting the src property − trackObject.src Following is the syntax for setting the src property − trackObject.src = "URL" Parameters The src property accepts a string value representing the URL or path to the track file. Common track file formats include: ...
Read MoreHTML DOM Video autoplay Property
The HTML DOM Video autoplay property sets or returns a boolean value that determines whether the video element will automatically start playing when the page loads. This property corresponds to the HTML autoplay attribute on the video element. Syntax Following is the syntax for getting the autoplay property value − mediaObject.autoplay Following is the syntax for setting the autoplay property − mediaObject.autoplay = booleanValue Parameters The booleanValue parameter can be one of the following − Value Description true The video will ...
Read MoreHTML DOM Video canPlayType( ) Method
The HTML DOM Video canPlayType() method returns a string indicating whether the browser can play the specified video type. This method helps determine video format compatibility before attempting playback, allowing developers to provide fallback options or choose the most suitable video format. Syntax Following is the syntax for the canPlayType() method − videoObject.canPlayType(type) Parameters The method accepts one parameter − type − A string specifying the MIME type of the video format to test (e.g., "video/mp4", "video/webm", "video/ogg"). Return Value The canPlayType() method returns one of three possible ...
Read MoreHTML DOM Video controls Property
The HTML DOM Video controls property returns or sets a boolean value that determines whether the video's standard playback controls (play, pause, volume, etc.) are displayed to the user. Syntax Following is the syntax for returning the controls property − mediaObject.controls Following is the syntax for setting the controls property − mediaObject.controls = booleanValue Parameters The booleanValue can be one of the following − Value Description true The video will display standard controls (play, pause, volume, progress bar, etc.) ...
Read MoreHTML DOM Video load( ) Method
The HTML DOM Video load() method is used to reload the video element after modifying its attributes such as the src or playback settings. When properties like defaultPlaybackRate, src, or video sources are changed, calling load() re-initializes the video element to apply these changes. Syntax Following is the syntax for the Video load() method − videoObject.load() Parameters The load() method takes no parameters. Return Value The method does not return any value. It simply reloads the video element with the updated attributes. When to Use load() Method The load() ...
Read MoreHTML DOM Video paused Property
The HTML DOM Video paused property returns a boolean value indicating whether the video is currently paused or playing. This read-only property is true when the video is paused and false when it is playing. Syntax Following is the syntax to access the paused property − videoElement.paused Return Value The property returns a boolean value − true − The video is currently paused false − The video is currently playing Example − Basic Paused Property Check Following example demonstrates how to check if a video is paused using ...
Read MoreHTML DOM Video playbackRate Property
The HTML DOM Video playbackRate property controls the speed at which a video plays. It returns a number representing the current playback speed, where 1.0 is normal speed, values greater than 1.0 increase speed, and values less than 1.0 decrease speed. Syntax Following is the syntax to get the current playback rate − mediaObject.playbackRate Following is the syntax to set a new playback rate − mediaObject.playbackRate = number Parameters number − A numeric value representing the playback speed. Common values include: 0.5 = Half speed (slow motion) ...
Read MoreHTML DOM Video poster Property
The HTML DOM Video poster property returns or sets the URL of an image that is displayed as a placeholder before the video starts playing or while the video is loading. This property corresponds to the poster attribute of the HTML element. Syntax Following is the syntax for getting the poster URL − mediaObject.poster Following is the syntax for setting the poster URL − mediaObject.poster = URLString Where mediaObject is a reference to the video element and URLString is the path or URL to the image file. Parameters ...
Read MoreHTML DOM Video seeking Property
The HTML DOM Video seeking property returns a boolean value indicating whether the user is currently seeking (moving the playback position) in the video. It returns true during the seeking process and false when not seeking. Syntax Following is the syntax for accessing the seeking property − videoObject.seeking Return Value The seeking property returns a boolean value − true − When the user is actively seeking (dragging the progress bar or using seek controls) false − When the video is playing normally or paused without seeking How It Works ...
Read More