A brief discussion on tags in HTML

A brief discussion on tags in HTML

0. What is a tag?

XML/HTML CodeCopy content to clipboard
  1. < input   type = "checkbox" checked /> < a   href = "http:www.jb51.net"   title = "123"   id = " lol " > Tips </a>   

Here checked, id, href, and title are tags.

1. Boolean flags

Checked as an example

Existence is application, used to mark the status,

If the flag is present, the value of getAttribute is always checked. If the flag is not present, the value of getAttribute is undefined.

By operating the value through setAttribute and removAttribute, it will act on the checked attribute, and the value of the checked attribute is true or false.

Assigning a value to the checked attribute will not have any effect on the checked flag.

2. Data labeling

Take title as an example

The value of the attribute title is always the same as the value of the tag title

The assignment of a value to the attribute title affects the existence (from nothing to something) and value of the tag title.

The above brief discussion on the tags in HTML is all the content that the editor shares with you. I hope it can give you a reference. I also hope that you will support 123WORDPRESS.COM.

<<:  Detailed explanation of using MySQL where

>>:  Do you know how to optimize loading web fonts?

Recommend

JavaScript Sandbox Exploration

Table of contents 1. Scenario 2. Basic functions ...

express project file directory description and detailed function description

app.js: startup file, or entry file package.json:...

Detailed explanation of the syntax and process of executing MySQL transactions

Abstract: MySQL provides a variety of storage eng...

Write a formal blog using XHTML CSS

The full name of Blog should be Web log, which mea...

Implementation of dynamic rem for mobile layout

Dynamic rem 1. First, let’s introduce the current...

5 ways to make your JavaScript codebase cleaner

Table of contents 1. Use default parameters inste...

How to print highlighted code in nodejs console

Preface When the code runs and an error occurs, w...

Summary of solutions to common Linux problems

1. Connect Centos7 under VMware and set a fixed I...

How to display div on object without being blocked by object animation

Today I made a menu button. When you move the mous...

jQuery plugin to achieve seamless carousel

Seamless carousel is a very common effect, and it...

Two methods to implement MySQL group counting and range aggregation

The first one: normal operation SELECT SUM(ddd) A...

Using vue3 to implement counting function component encapsulation example

Table of contents Preface 1. The significance of ...

In-depth analysis of MySQL data type DECIMAL

Preface: When we need to store decimals and have ...

IIS7~IIS8.5 delete or modify the server protocol header Server

Requirements: Remove HTTP response headers in IIS...