ooglewindowblinds.com

Easy and Free adobe CS photoshop tutorials and lessons online

HTML Links:

February 18th, 2008 · No Comments

On the internet, you often have to link your document with another document. For this, HTML links are used.
The first thing you have to understand is that to link to a document on the internet, HTML used the <a> tag.  This is known as the ‘anchor’ tag as by using it, you actually specify the location of the anchor to be anchor linked from. The <a> is used with the href attribute as it locates the address of the document to link to. So, when used together, the tag becomes <a href> and just like all other HTML tags, a closing tag is required i.e. </a> and the words between the open and close of the anchor tag are displayed as a hyperlink.
The idea can be fully grasped by the following code. See this HTML link tutorial example below.
<html>
<body>
<a href=”http://www.google.com/”>Click here toVISIT GOOGLE</a>
<p><a href=”http://www.msn.com/”>Click here to VISIT MSN</a>
</body>
</html>
However, we don’t use just the ‘href’ attribute in linking. The target attribute is used to address the target area where the link will be opened. The target attribute when used with the anchor and href tag looks like <a href=”website address” target=”_blank”> text </a>.
You can even use the ‘anchor’ tag with the ‘name’ attribute. The name attribute names the anchor and when used, looks like: <a name=”name of your choice”> text </a>. To hyperlink to a portion within the same webpage, we use a ‘#’ character with the anchor. The tag looks like this: <a href=”#name”> Go to the “name” of your webpage </a>.

Tags: HTML tutorials

0 responses so far ↓

  • There are no comments yet...Kick things off by filling out the form below.

You must log in to post a comment.