Common HTML tags

1. Label semantics

Simple understanding refers to the meaning of the label, that is, what the label is used for. According to the semantics of the label, giving the most suitable label in the right place can make the page structure clearer.

2. Title tag (important)

In order to make web pages more linguistic, we often use title tags in the pages. HTML provides 6 levels of page titles, namely <h1>-<h6>.

    2.1 The grammatical format of the title tag

        <h1>Title tag <h1>
        The abbreviation of the word head, which means head, title.
       Tag semantics: used as a headline, and is decreasing in importance

    2.2 Features of Title Tag

        >The captioned text will become bold and the font size will increase in turn
        .>One caption occupies one line.

    2.3 Case

Code

Results

3. Paragraph tags and line break tags (important)

 Paragraph tag

    In a web page, to display text in an orderly manner, these texts need to be displayed in segments. In HTML tags, the <p> tag is used to define paragraphs, it can divide the entire web page into several paragraphs

   3.1 Format of paragraph tags

        <p>Paragraph tag</p> The abbreviation of the word paragraph, which means paragraph

        Tag semantics: HTML document can be divided into several paragraphs

   3.2 Characteristics of paragraph tags

      >The text in a paragraph will automatically wrap according to the size of the browser window
      >There is a gap between the paragraph and the paragraph

  Newline label

    In HTML, the text in a paragraph will be arranged from left to right until the right end of the browser window, and then automatically wrap. If you want a certain text to be forced to wrap, you need to use a wrap tag</br>

    3.3 Format of line break label

     <br/> 

    3.4 Case

    The picture is the introduction of the movie Fallen Angel

    This is what we do when we don’t use paragraph tags

    As we can see, the level is unclear, and I read an article of confusion. The picture below is after I used the paragraph tag

    Paragraph tags, the chaotic text becomes orderly, if we add a line break tag in it

    The effect presented

4. Text formatting tags

   In web pages, sometimes it is necessary to set bold, italic, and underline effects for text. At this time, you need to use text formatting tags in HTML to display text in a special way.

   Tag semantics: highlight the importance, more important than ordinary text.

Recommended

  Recommended browser: Google Chrome

  Recommended Java environment: eclipse, IDEA

  Recommended learning this week: HTML and CSS

  Recommended learning video link:  https://www.bilibili.com/video/BV1CK411G7m4?from=search&seid=9778818247834758128

  Recommended HTML environment: VScode (Visual Studio Code)

 

 

 

 

 

 

 

 

Guess you like

Origin blog.csdn.net/weixin_52011642/article/details/110849388