Get the App
SLTechnology News&Howtos  ›  Development  › 

How to use the & lt;base> tag of HTML

Shulou Source: shulou.com Published: 2022-06-01 10:37:27 09月30日 Update

This article mainly introduces the relevant knowledge of "how to use HTML tags". Xiaobian shows you the operation process through actual cases. The operation method is simple and fast and practical. I hope this article "how to use HTML tags" can help you solve the problem.

I. Grammar and structure

Second, Html base hyperlink default open address and open way label use instructions

1. Target value:

1,_blank New window opens URL link

2._parent Refresh this page and open the corresponding URL address

3、_self

4、_top

Here the target value is the same as the target value of the a link

2. Href value:

It can be a URL address.

III. Introduction to Base

The Base tag specifies a default address or destination for all links on the page.

A hyperlink (anchor text) address in html web pages does not have a link with http URL (domain name), the default browser will open the link and add the base tag to set the URL address.

If there is no target opening method in a hyperlink in HTML pages, the default browser will set the opening method of its base setting.

IV. Base Label Use Case Code

html base links default open vs. default URL address tag element example

- WWW.. COM instance demonstration

I am!

HTML basics!

V. Effect example diagram

html base Web page links default open

This label explains the case:

In this base tag case, the base tag is used, and the opening mode is set to open a new window (target="_blank"), and the URL address is http://www. com/(href="http://www.. com/")。If the hyperlink anchor text a on the web page does not have an absolute URL (no address path with domain name), when browsing in the browser, the browser will obtain the element set by base by default, and the above situation occurs. Anchor text a hyperlink.

This case page is in the next space, the user clicks on "html base", a new window will open "http://www.. com/html/.

About "HTML tags how to use" content is introduced here, thank you for reading. If you want to know more about industry-related knowledge, you can pay attention to the industry information channel. Xiaobian will update different knowledge points for you every day.

Tags: Links tags addresses methods web pages browsing cases browsers text knowledge URLs elements domain names foundations methods goals examples industries different practical Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno Shulou Tech Info NVidia Microsoft Apple Xiaomi