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 on Trending Technologies
Technical articles with clear explanations and examples
HTML 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 MoreHow to include another HTML file in an HTML file?
In this tutorial, we will learn different methods to include another HTML file within an existing HTML file. This technique is useful for creating reusable components, headers, footers, or content sections that can be shared across multiple pages. Several methods are available to include external HTML files, each with its own advantages and use cases. Let us explore the most effective techniques that have proper web browser support. Using jQuery Load Method The jQuery load() method is one of the most popular approaches for dynamically including HTML content. It fetches content from an external file and inserts ...
Read MoreHow to use media queries in a mobile-first approach in HTML?
The mobile-first approach is a responsive web design strategy where you start by designing and coding for mobile devices first, then progressively enhance the layout for larger screens using CSS media queries. This approach ensures better performance on mobile devices and creates a solid foundation for scalability across all screen sizes. In mobile-first design, you write base CSS styles for small screens (mobile devices) and then use media queries with min-width breakpoints to add or override styles for tablets, desktops, and larger displays. This approach is opposite to the desktop-first method, where you start with desktop styles and use ...
Read MorePOST unchecked HTML checkboxes
In HTML forms, checkboxes that are unchecked are not included in form submissions by default. This can create issues when you need to track the state of all checkboxes, not just the ones that are checked. This tutorial demonstrates how to POST unchecked HTML checkboxes to ensure complete form data is sent to the server. HTML forms typically send only data from checked checkboxes when using POST or GET methods. Unchecked checkboxes are omitted entirely from the submitted data, making it impossible for the server to distinguish between an unchecked checkbox and a checkbox that doesn't exist. This behavior ...
Read MoreHow to add Flash content within a webpage in HTML?
Flash content was once a popular multimedia technology for adding interactive elements like animations, games, and videos to web pages. However, Adobe Flash is now officially discontinued (end-of-life December 2020) and modern browsers have removed Flash support entirely due to security vulnerabilities and performance issues. This article covers the historical methods for embedding Flash content using HTML, but strongly recommends using modern alternatives like HTML5, CSS, and JavaScript for multimedia content in today's web development. Historical Flash Embedding Methods There were two primary approaches for embedding Flash content in HTML − Using the ...
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 More