XHTML introductory learning tutorial: XHTML hyperlink_HTML/Xhtml_web page production

WBOY
Release: 2016-05-16 16:44:37
Original
1524 people have browsed it

Hyperlink tag
It is no exaggeration to say that hyperlinks connect the entire Internet. A hyperlink can point to almost any resource on the Internet, such as another web page, a picture, an MP3 song, etc. The syntax for using XHTML to create hyperlinks is very simple. It only requires a pair of
tags:
Text or pictures to be displayed on the page
For example:
Script Home
will be displayed as a hyperlink in the browser. Click it and you will enter the script home (http://www.jb51.net/). The effect is as follows:
Script Home
The href attribute in the tag is the address to which this hyperlink points. It can be a general URL or an email address. In a later exercise example, we will create a hyperlink pointing to the email address. Link. The content (element) between and will be displayed as a hyperlink on the web page. Note that when the href attribute value is a general URL (absolute path), its "http://" cannot be omitted, otherwise the browser will recognize it as a relative path. The difference between absolute paths and relative paths is beyond the scope of this XHTML tutorial. If you don't understand, you can search for relevant information on Baidu. In-page jump hyperlink (anchor)
You may have noticed when browsing other websites that there are some hyperlinks that can take you back to the top of the page or to any location within the current web page. Like this link:
Back to title
The implementation method is as follows, first add the following code to the title. :

XHTML introductory learning tutorial - XHTML hyperlink


The code of the hyperlink itself is:
Back to title
Jumps within the page can allow your users to quickly find the information they need when there is a lot of content on your page. Usually it is used as a directory within some explanatory web pages. Link exercises
The following practice adds a hyperlink to the previous "index.html". Open "index.html" and make the following modifications to the code:

Intermediate code omitted...

Contact me


Copyright©2005-2006XXX Copyright not available



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
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!