Home > Web Front-end > Front-end Q&A > How to position html

How to position html

藏色散人
Release: 2021-06-03 14:31:04
Original
3980 people have browsed it

HTML positioning method: First create an HTML sample file; then use the a tag to write three menus and content; then add the name attribute to the a tag of each content title and add "# link" ;Finally, add a specific page in front of "#" to automatically locate the specific location of this page.

How to position html

The operating environment of this article: Windows7 system, HTML5&&CSS3 version, Dell G3 computer.

As shown in the picture, there are three menus at the top: "Character Profile", "Deeds Introduction", and "Other Instructions", and then the following is the specific content display of each menu. When we need to click on the above menu, the page will automatically Locate the corresponding content

How to position html

as shown in the picture, we first write three menus, use the a tag

How to position html

## and then Write the content of each menu below

How to position html

The key point is to add the name attribute to the a tag of each content title (add the name attribute to other tags, above The menu cannot be located)

How to position html

Then add links to each a tag in the menu above: starting with "#" and adding the corresponding name attribute

How to position html

Different pages can also be positioned. Just add the specific page in front of "#", and then the specific location of the page will be automatically positioned

How to position html

[Recommended learning:

html video tutorial]

The above is the detailed content of How to position html. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template