Jump to content

{Tutorial}HTML Links.Step 9.


MrHotFire

Recommended Posts

HTML Hyperlinks (Links)

 

The HTML <a> tag defines a hyperlink.

 

A hyperlink (or link) is a word, group of words, or image that you can click on to jump to another document.

 

When you move the cursor over a link in a Web page, the arrow will turn into a little hand.

 

The most important attribute of the <a> element is the href attribute, which indicates the link’s destination.

 

By default, links will appear as follows in all browsers:

 

    An unvisited link is underlined and blue

    A visited link is underlined and purple

    An active link is underlined and red

 

HTML Link Syntax

 

The HTML code for a link is simple. It looks like this:

<a href="url">Link text</a> 

The href attribute specifies the destination of a link.

Example:

<a href="http://www.mrhotfire.com/">Visit MrHotFire</a>

which will display like this: Visit MrHotFire

 

Clicking on this hyperlink will send the user to MrHotFire's homepage.

 

Tip: The "Link text" doesn't have to be text. It can be an image or any other HTML element.

HTML Links - The target Attribute

 

The target attribute specifies where to open the linked document.

 

The example below will open the linked document in a new browser window or a new tab:

<a href="http://www.mrhotfire.com/" target="_blank">Visit MrHotFire!</a>

HTML Links - The id Attribute

 

The id attribute can be used to create a bookmark inside an HTML document.

 

Tip: Bookmarks are not displayed in any special way. They are invisible to the reader.

Example:

<a id="Mr">HotFire</a> 

<a href="#Mr">HotFire</a>

<a href="http://www.mrhotfire.com/doyoulike/it">
Do you like it</a> 

 

HTML Link Tags

Tag	Description
<a>	Defines a hyperlink

 

Credits Olympus,Internet,ME.

 

 

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.



×
×
  • Create New...