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
Articles by AmitDiwan
Page 261 of 840
HTML DOM Input URL size Property
The Input URL size property in HTML DOM controls the visible width of a URL input field. It specifies how many characters the input field displays at once. If not defined, this property returns the default value of 20. Syntax Following is the syntax for returning the size attribute − inputURLObject.size Following is the syntax for setting the size property to a number − inputURLObject.size = number Parameters The size property accepts a numeric value representing the number of characters visible in the input field. The value should be ...
Read MoreHTML DOM Anchor type Property
The HTML DOM Anchor type property sets or retrieves the value of the type attribute of an anchor element. This property specifies the MIME type of the linked resource, providing a hint to the browser about the content type it can expect when following the link. The type attribute was introduced in HTML5 and serves as a suggestion to help browsers optimize how they handle the linked resource. It contains a single MIME (Multipurpose Internet Mail Extensions) type value such as text/html, application/pdf, or image/jpeg. Syntax Following is the syntax for getting the type property − ...
Read MoreHTML DOM Table tBodies Collection
The HTML DOM table tBodies Collection returns a collection of all elements within a specific table element. This collection is live, meaning it automatically updates when elements are added or removed from the table. Syntax Following is the syntax to access the tBodies collection − tableObject.tBodies Where tableObject is a reference to an HTML table element obtained through methods like document.getElementById() or document.querySelector(). Properties The tBodies collection has the following property − Property Description length Returns the number of elements in ...
Read MoreHTML DOM Anchor username Property
The HTML DOM anchor username property is used to set or return the username portion of a URL in an anchor element's href attribute. The username appears in URLs that use basic authentication format: protocol://username:password@hostname. Syntax Following is the syntax for returning the username property − anchorObject.username Following is the syntax for setting the username property − anchorObject.username = "newUsername" Parameters The username property accepts a string value representing the username portion of the URL. When setting this property, it modifies only the username part while keeping the rest ...
Read MoreHTML DOM Datalist options Collection
The HTML DOM Datalist options collection represents all the elements contained within a element. This collection provides methods and properties to access and manipulate the options programmatically. The elements appear in the same order as they are defined in the HTML document. Syntax Following is the syntax for accessing the Datalist options collection − datalistObject.options This returns an HTMLOptionsCollection object containing all the elements within the datalist. Properties The Datalist options collection provides the following property − Property Description length Returns ...
Read MoreHTML DOM Video textTracks Property
The HTML DOM Video textTracks property returns a TextTrackList object containing information about all text tracks associated with a video element. Text tracks include subtitles, captions, descriptions, chapters, and metadata that can be displayed alongside video content. Syntax Following is the syntax to access the textTracks property − videoElement.textTracks Return Value The property returns a TextTrackList object that contains − length − The number of text tracks available Individual tracks − Each track can be accessed by index with properties like label, language, kind, and mode Methods − getTrackById() to find ...
Read MoreHTML DOM Input URL value Property
The HTML DOM Input URL value property allows you to get or set the value of an HTML input element with type="url". This property returns the current URL string in the input field or sets it to a new URL value programmatically. Syntax Following is the syntax for getting the URL value − inputURLObject.value Following is the syntax for setting the URL value − inputURLObject.value = "URL_string" Parameters The value property accepts the following parameter − URL_string − A string representing a valid URL that will be ...
Read MoreHTML DOM AnimationEvent
The HTML DOM AnimationEvent is a JavaScript object that handles events occurring during CSS animations. It provides detailed information about animation-related events and offers greater control over CSS animations by describing which events triggered specific animations. Properties The AnimationEvent object contains three main properties − Property Description animationName Returns the name of the CSS animation being executed. elapsedTime Returns the time elapsed since the animation started running, measured in seconds. pseudoElement Returns the name of the pseudo-element where the animation occurs (e.g., ::before, ::after, ::first-line). Returns ...
Read MoreHTML DOM Table tHead Property
The HTML DOM table tHead property returns the element of a table. This property provides access to the table's header section, allowing developers to manipulate or retrieve the header content programmatically. Syntax Following is the syntax for accessing the tHead property − table.tHead Return Value The tHead property returns − A HTMLTableSectionElement representing the element if it exists. null if the table has no element. Example − Accessing Table Header Following example demonstrates how to use the tHead property to access ...
Read MoreHTML DOM Video volume Property
The HTML DOM Video volume property sets or retrieves the audio volume level of a video element. The volume is represented as a decimal number between 0.0 (muted) and 1.0 (maximum volume). Syntax Following is the syntax for returning the current volume − mediaObject.volume Following is the syntax for setting the volume to a specific level − mediaObject.volume = number Parameters The number parameter accepts a decimal value with the following constraints − Maximum value − 1.0 (full volume) Minimum value − 0.0 (muted/silent) Default value − ...
Read More