Articles on Trending Technologies

Technical articles with clear explanations and examples

How do we add a definition term in HTML?

Bhanu Priya
Bhanu Priya
Updated on 16-Mar-2026 622 Views

The definition term is represented by the tag in HTML, which describes the name or term in a description list. The element works in conjunction with and tags to create structured definition lists. tag defines a description list container tag defines the term being described tag provides the description or definition for each term The tag supports both global and event attributes and is supported by all modern browsers. Syntax Following is the syntax for creating definition terms − Term ...

Read More

Set the language of the track text data in HTML

Abhinanda Shri
Abhinanda Shri
Updated on 16-Mar-2026 203 Views

The srclang attribute in HTML5 is used to specify the language of the track text data. This attribute is essential when working with elements to provide subtitles, captions, descriptions, or other text tracks for multimedia content. The srclang attribute helps browsers and assistive technologies understand what language the track content is written in. Syntax Following is the syntax for the srclang attribute − The language-code should be a valid BCP 47 language tag, such as "en" for English, "es" for Spanish, or "fr" for French. Parameters The srclang attribute accepts ...

Read More

How to create a bookmark link in HTML?

Lokesh Badavath
Lokesh Badavath
Updated on 16-Mar-2026 15K+ Views

A bookmark link in HTML allows users to jump to specific sections within the same webpage or to sections on different pages. Bookmarks are particularly useful for long documents, creating table of contents, or providing quick navigation to important sections. HTML bookmarks work by combining the id attribute to mark target sections and anchor links with hash (#) references to jump to those sections. When clicked, the browser automatically scrolls to the bookmarked location. Syntax To create a bookmark link, first add an id attribute to the target element − Section Heading Then ...

Read More

How to specify the URL of the image to use in different situations in HTML?

Smita Kapse
Smita Kapse
Updated on 16-Mar-2026 388 Views

Use the srcset attribute to specify the URL of the image to use in different situations in HTML. This attribute allows you to provide multiple image sources for responsive images, enabling browsers to choose the most appropriate image based on screen size, resolution, or other conditions. Syntax The srcset attribute can be used in two main ways − Using srcset with img Element The srcset attribute on the element allows you to specify multiple image sources with their respective widths or pixel densities. The browser automatically selects ...

Read More

HTML DOM Input Checkbox Object

Kumar Varma
Kumar Varma
Updated on 16-Mar-2026 546 Views

The HTML DOM Input Checkbox Object represents an HTML input element with type "checkbox". It provides properties and methods to interact with checkbox elements programmatically, allowing you to get or set their state, value, and other attributes through JavaScript. Syntax Following is the syntax to create a checkbox element using JavaScript − var checkboxObject = document.createElement("input"); checkboxObject.type = "checkbox"; To access an existing checkbox element − var checkboxObject = document.getElementById("checkboxId"); // or var checkboxObject = document.getElementsByName("checkboxName")[0]; Properties The Input Checkbox Object has the following properties − ...

Read More

HTML DOM Input FileUpload autofocus Property

AmitDiwan
AmitDiwan
Updated on 16-Mar-2026 163 Views

The HTML DOM Input FileUpload autofocus property controls whether a file upload input field automatically receives focus when the page loads. This property corresponds to the HTML autofocus attribute and can be used to programmatically set or check the autofocus state of file input elements. Syntax Following is the syntax for getting the autofocus property value − inputFileUploadObject.autofocus Following is the syntax for setting the autofocus property − inputFileUploadObject.autofocus = booleanValue Return Value The autofocus property returns a boolean value indicating whether the file upload input has autofocus enabled ...

Read More

How to create HTML link that doesnt follow the link?

Sreemaha
Sreemaha
Updated on 16-Mar-2026 466 Views

The nofollow attribute in HTML creates a link that doesn't pass SEO authority to the target page. When you add rel="nofollow" to a link, it tells search engines not to follow the link or transfer any ranking credit to the destination website. Syntax Following is the syntax to create a nofollow link − Link Text The rel attribute specifies the relationship between the current document and the linked document. When set to "nofollow", it instructs search engines not to follow the link. Understanding Nofollow Links The rel="nofollow" attribute serves several purposes − ...

Read More

How do we include the legal number intervals for an input field in HTML?

radhakrishna
radhakrishna
Updated on 16-Mar-2026 366 Views

The step attribute in HTML defines the legal number intervals for input fields. It specifies the increment value that users can select, creating a controlled range of acceptable values. The step attribute works with numeric input types like number, range, date, datetime-local, month, time, and week. Syntax Following is the syntax for the step attribute − The value can be a positive number, decimal, or the keyword any. When combined with min and max attributes, it creates a complete range validation system. Step Attribute with Number Input The step attribute controls ...

Read More

HTML DOM Input Checkbox required Property

Rama Giri
Rama Giri
Updated on 16-Mar-2026 448 Views

The HTML DOM Input Checkbox required property determines whether a checkbox input must be checked before a form can be submitted. This property corresponds to the HTML required attribute and provides a way to enforce mandatory checkbox selections in web forms. Syntax Following is the syntax for getting the required property value − inputCheckboxObject.required Following is the syntax for setting the required property − inputCheckboxObject.required = booleanValue Return Value The required property returns a Boolean value − true − The checkbox is required and must be checked ...

Read More

Execute a script before the document is printed in HTML?

Yaswanth Varma
Yaswanth Varma
Updated on 16-Mar-2026 425 Views

The onbeforeprint attribute in HTML is an event handler that executes a JavaScript function before a document is printed. This attribute triggers when the user attempts to print the page through browser print functionality (Ctrl+P, File → Print, or print button), displaying custom messages or performing actions before the print dialog appears. The onbeforeprint event is commonly used together with the onafterprint attribute to handle print preparation and cleanup tasks. It belongs to the HTML event attributes category and can be applied to the element or used with JavaScript event listeners. Syntax Following is the syntax ...

Read More
Showing 13691–13700 of 61,297 articles
Advertisements