Home >Web Front-end >HTML Tutorial >Summarize the usage and jump methods of a tag in HTML
This article will give you a summary of how to use the a tag and how to jump. I hope it will be helpful to you!
1. How to jump and use the a tag
The most important attribute of the a element is the href
attribute, which indicates The target of the link. There are five ways to jump to the
a tag:
written as
<a href="http://vue.ydui.org/docs/#/flexbox" target="value"></a>
##_blank means jumping to a new page to open, open a New window
_self represents the current page open link
_parent represents the parent set frame Open in
_top means open in the entire window
framename means open in the specified How to jump to the page when
# is opened in the frame, that is, the attribute value needs to be added to the target
2, a How the tag jumps to the specified position
name attribute is used to specify the name of the anchor. Add
# in href and then add the name value of the place to be jumped so that you can jump to the specified location
<ul> <li><a href="#C1">第一章</a></li> <li><a href="#C2">第二章</a></li> <li><a href="#C3">第三章</a></li> </ul> <h2><a name="C1">第一章</a></h2> <p>本章讲解的内容是 ... ...</p> <h2><a name="C2">第二章</a></h2> <p>本章讲解的内容是 ... ...</p> <h2><a name="C3">第三章</a></h2> <p>本章讲解的内容是 ... ...</p>
3. How to make a phone call with a tag
To use the a tag to dial a phone number, just add tel and number to the href.<a href="tel:123456789"></a>Recommended: "
HTML Video Tutorial"
The above is the detailed content of Summarize the usage and jump methods of a tag in HTML. For more information, please follow other related articles on the PHP Chinese website!