HTML Articles

Page 38 of 151

Difference between HTML and HTTP

Pranavnath
Pranavnath
Updated on 16-Mar-2026 3K+ Views

HTML and HTTP are foundational technologies of the web that work together but serve different purposes. HTML (HyperText Markup Language) is a markup language used to create and structure web pages, while HTTP (HyperText Transfer Protocol) is a communication protocol that transfers web content between servers and browsers. What is HTML? HTML (HyperText Markup Language) is a markup language used to create the structure and content of web pages. It uses tags to define elements like headings, paragraphs, links, images, and forms that make up a webpage's content and layout. HTML Syntax HTML documents are structured ...

Read More

HTML DOM InputEvent inputType Property

AmitDiwan
AmitDiwan
Updated on 16-Mar-2026 150 Views

The HTML DOM InputEvent inputType property returns a string indicating the type of input action that triggered an input event. This property helps identify whether the user is typing text, deleting content, pasting, or performing other input operations on form elements. Syntax Following is the syntax for accessing the inputType property − event.inputType Return Value The inputType property returns a string representing the type of input. Common values include − "insertText" − When user types regular text "deleteContentBackward" − When user presses Backspace "deleteContentForward" − When user presses Delete "insertParagraph" − ...

Read More

HTML DOM Label htmlFor Property

AmitDiwan
AmitDiwan
Updated on 16-Mar-2026 244 Views

The HTML DOM Label htmlFor property is used to get or set the value of the for attribute of a label element. The for attribute creates an association between a label and a form control, improving accessibility and user experience by allowing users to click the label to focus or activate the associated form element. Syntax Following is the syntax for getting the for attribute value − labelObject.htmlFor Following is the syntax for setting the for attribute value − labelObject.htmlFor = "elementId" Return Value The htmlFor property returns a ...

Read More

How to make div with left aligned text and right aligned icon using CSS ?

Saba Hilal
Saba Hilal
Updated on 16-Mar-2026 2K+ Views

Creating a div with left-aligned text and right-aligned icon is a common layout requirement in web development. The element serves as a container that can hold both text content and icons in a structured format. Using CSS, we can position these elements precisely within the same horizontal line. This article demonstrates three different CSS approaches to achieve this layout: the float property, CSS flexbox, and CSS table display methods. Each technique offers unique advantages for different scenarios. Icon Used in Examples All examples use the Material Icons library to display an "album" icon. The following setup ...

Read More

How to autoplay audio on chrome?

Aayush Mohan Sinha
Aayush Mohan Sinha
Updated on 16-Mar-2026 11K+ Views

Modern web browsers, including Chrome, have strict autoplay policies that prevent audio from playing automatically without user interaction. This is designed to improve user experience and prevent unwanted sounds. However, there are legitimate ways to implement audio autoplay functionality while respecting these browser policies. In this article, we will explore different approaches to handle audio autoplay in Chrome, understanding both the technical implementation and the browser limitations that developers must work within. Chrome's Autoplay Policy Chrome blocks autoplay audio unless one of these conditions is met − The user has interacted with the page (clicked, ...

Read More

How to design mobile touch slider using Swiper.js Plugin?

Aayush Mohan Sinha
Aayush Mohan Sinha
Updated on 16-Mar-2026 675 Views

The Swiper.js plugin is a powerful JavaScript library for creating mobile-friendly touch sliders with smooth animations and intuitive navigation. It provides extensive customization options, making it ideal for building responsive image carousels, content sliders, and interactive galleries that work seamlessly across all devices. Syntax Following is the basic HTML structure for implementing Swiper.js − Slide content Slide content Following is the JavaScript initialization syntax − const swiper = new Swiper('.swiper', ...

Read More

How to create and read the value from cookies

Aman Gupta
Aman Gupta
Updated on 16-Mar-2026 625 Views

Cookies are small pieces of data stored in the user's browser by web applications. They consist of name-value pairs and are sent back to the server with each HTTP request, allowing websites to remember user information across sessions. Syntax Following is the syntax to create a cookie using JavaScript − document.cookie = "cookieName=cookieValue; expires=date; path=/"; Following is the syntax to read cookies − var allCookies = document.cookie; Parameters cookieName − The identifier for the cookie (e.g., "username", "sessionId"). cookieValue − The data stored in the ...

Read More

HTML DOM Legend form Property

AmitDiwan
AmitDiwan
Updated on 16-Mar-2026 168 Views

The HTML DOM Legend form property returns a reference to the form element that contains the element. This property is read-only and provides access to the parent form for DOM manipulation and validation purposes. Syntax Following is the syntax for accessing the form property − legendObject.form Return Value The form property returns a reference to the HTMLFormElement object that contains the legend, or null if the legend is not inside a form. Example Let us see an example demonstrating the Legend form property − ...

Read More

How to Search the Parse Tree using BeautifulSoup?

Tapas Kumar Ghosh
Tapas Kumar Ghosh
Updated on 16-Mar-2026 287 Views

BeautifulSoup is a Python library for parsing HTML and XML documents and searching through the parse tree. The find() and find_all() methods are the most commonly used approaches for locating specific elements within the parsed document structure. BeautifulSoup creates a parse tree from HTML/XML documents, allowing you to search, navigate, and modify the content easily. It provides a simple API that works well for beginners and offers comprehensive documentation for quick learning. Installation Before using BeautifulSoup, install it using pip − pip install beautifulsoup4 Syntax Following are the main methods used for ...

Read More

HTML DOM li value Property

AmitDiwan
AmitDiwan
Updated on 16-Mar-2026 212 Views

The HTML DOM li value property allows you to get or set the value attribute of a element. This property is particularly useful when working with ordered lists where you need to control the numbering sequence or create custom list item values. Syntax Following is the syntax for getting the value attribute − liObject.value Following is the syntax for setting the value attribute − liObject.value = "string" Parameters string − A string value that represents the numeric value for the list item. This must be a ...

Read More
Showing 371–380 of 1,509 articles
« Prev 1 36 37 38 39 40 151 Next »
Advertisements