Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

What are the basic tags of HTML

2025-01-22 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Development >

Share

Shulou(Shulou.com)06/01 Report--

In this article, the editor introduces in detail "what are the basic tags of HTML", the content is detailed, the steps are clear, and the details are handled properly. I hope this article of "what are the basic tags of HTML" can help you solve your doubts? let's follow the editor's ideas to learn new knowledge.

What is HTML:

Hypertext markup language, a text-only language; use "tags" with "angle brackets" to identify the content in a web page

Tag syntax:

The symbols used by HTML to describe functions are called "tags".

Tags must be enclosed in "angle brackets" when used

Close the mark:

Closed tags, also known as double tags, must appear in pairs; content

Non-closed mark:

Also known as an empty tag or a single tag; or

Xhtml became the W3C standard in January 2000; Xhtml is the stricter and purer version of HTML

HTML document structure:

1. Declaration-document type declaration; declaration must be written at the beginning of the document

2. Page / document--

3. Page header-the information of the main loading page

4. Page body--

Document title: give the page a name

Each tag has attributes, which can be one or more, separated by spaces

Composition of attributes: attribute name = "attribute value"

Attribute must be written inside the opening tag

HTML comments: content that only programmers can see and will not display on a web page

It must not exist in the comment content--

No matter how many spaces are typed in the HTML page, only one space will be displayed.

To have multiple spaces, you must use escape characters

Escape character:

Spaces--

Left angle bracket

Copyright? -?

Registered trademark -?

Newline tag:

Force no line wrapping tag: no line wrap content

Title mark: nasty 1, 2, 3, 4, 5, 6.

Paragraph marks:

Text style labels:

Text bold

Text tilt

Add underscore

Add delete line

All the above tags are not recommended and have been discarded.

Emphasize the text, as shown by the bold text

Emphasize the text, as shown by the tilt of the text

Superscript mark

Subscript mark

Label classification:

Block-level tags: by default, block-level tags occupy an exclusive line, and the contents of the element will automatically wrap before and after the line

Inline tags: do not wrap and can be on the same line as other inline elements

B 、 i 、 u 、 s 、 strong 、 em 、 sup 、 sub

Zone label:

Preformat the label:

The content written in the tag will be displayed on the web page in the format in which it was written.

Page Properties:

Background color-bgcolor

Page text color-text

Font label:

Font color-color

Font-face

Font size-size; minimum 1, maximum 7

The label has been discarded

Directory structure:

The location of all files under a project (web site); a web site contains multiple directories, each containing different parts of the site; the home directory of the web site is called the root directory; other folders located under the root directory are called subdirectories; each subdirectory contains the next level of subdirectories for specific functions

All file names must be in English, numbers, underscores (_) and hyphens (-).

URL:

Uniform resource location Unified Resource Locator

Used to identify any resource in the network

The path, which refers to the route from the current position to the target location.

URL classification:

1. Absolute path: 192.168.101.111

Http:// / images / img01.jpg

Protocol name hostname directory path file name

Used to point to files on other devices

2. Relative path:

The location of the target file is relative to the location of the current file

The target file and the current file are in the same directory, write the file name directly-img01.jpg

The folder where the target file is located is in the same directory as the current file-- folder name / file name images/img01.jpg

If the target file and the current file are not in the same directory, the directory is returned to the next level, and one is returned to the first level.

3. Root relative path:

For server

Horizontal Center label:

The label has been discarded

The alignment attribute of the tag:

Align= "left"

Align= "right"

Align= "center"

Horizontal split line label:

Width-width, preferably with unit px

Height-size, without units

Align-align

Color-color

Image label:

Link image address-src= "path"

Width-width, only the width is given, and the height changes automatically in proportion.

Height-height, only the height is set, and the width changes automatically.

Title-- prompt text after mouse movement, used to describe the picture

The alternate text used by alt-- when the picture does not display properly.

Hyperlink tag:

Link attribute-href= "path"

Empty link: 1. Href= "", which will return to the top.

2. Href= ""

Picture: href= "picture path", you can point the link to a picture

Compressed package: href= "", point to a compressed package, and click to download it.

Send email: href= "email address", you can send email to this mailbox

The destination where the target-- link is opened

Target= "_ blank" to open the link in a new window

Target= "_ self" to open a link on the current page

Anchor name-name, tag, to which you can point the link to achieve the effect of jumping to the specified location on the page

After reading this, the article "what are the basic tags of HTML" has been introduced. If you want to master the knowledge points of this article, you still need to practice and use it yourself to understand it. If you want to know more about related articles, welcome to follow the industry information channel.

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Development

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report