Copyright © 2009 | This site is owned and operated by ballmarketing.net | All Rights Reserved | Contact Us
Email Marketing Course:
Free Publication:
the free "Internet Business Beginners' Guide"
-----------------
-----------------
New Guidebook:
----------------
Business Course:
Basic Anchor 'A' Tag
HTML tags and their attributes which are used to insert links in web pages:
<a> (anchor tag): The HTML tag used to link to another document or where you specifiy in the tag. It can be another website, a different page in your website or a different place on the same page. The anchor tags require end tags: <a>.........</a>
- href: an attribute of the anchor tag which specifies the URL of the target destination (where the user will be taken when link is clicked on).
example: <a href="216_Web_Safe_Colors_Chart.html">216 Web Safe Colors</a>
- target: an attribute of the anchor tag which specifies where the target page should be displayed - in the same browser window as the link, in a new window, etc.
example: <a href="216_Web_Safe_Colors_Chart.html" TARGET="BLANK" >216 Web Safe Colors</a>
Looks like this: 216 Web Safe Colors They look the same but adding Target="Blank" into the tag opens the link up into a new window.
Here are some examples of these HTML tags in use:
Below is a sample link that takes you to the Ball Marketing Home Page:
To go to the Ball Marketing.net home page, click here
In actual HTML, the code for this link would look like this:
example: To go to the Ball Marketing.net home page, click
<a href="http://www.ballmarketing.net">here</a>
Notice in the example above that you are only able to click on the word "here!" This is because the word "here!" is located between the opening anchor tag (<a >) and the closing anchor tag (</a>). Because this is an anchor tag, you need to show where you wish the user to go once the link is clicked.
The "HREF" attribute allows you to specify a location, called a URL, for this destination. In the above example, the user will be taken to the default Ball Marketing.net home page; the URL for this page is: "http://www.ballmarketing.net".
To specify any other page within your site, you need to include the directory and/or page name, such as in this link:
To go to the Ball Marketing.net Articles page, click here
Which would look like this in HTML code: To go to the Ball Marketing.net Articles page, click <a href="Articles.html">here!</a>
Looks like this: To go to the Ball Marketing.net Articles page, click here!
The above example will open the destination page in the same browser window as the current page (where the link is). unless you add the target tag to the anchor tag to open the destination page in a new browser window,
Which would look like this in HTML code: To go to the Ball Marketing.net Articles page, click <a href="Articles.html" target="_blank">here!</a>
Looks like this: To go to the Ball Marketing.net Articles page, click here!
- <img> (image tag): the HTML tag used when displaying an image on a web page. It does not require an end tag.
src (source): an attribute of the image tag which specifies the URL where the image is located.
border: an attribute of the image tag which specifies whether a border should be displayed around the image. Image tag: Below is an example that displays an image:

Note that in order to display an image properly, you must provide the location where this image actually resides in the "SRC" attribute. The URL address (or pathname) for the image can be either relative or absolute.
A relative pathname points to a file or directory relative to the current file's directory, which means the destination file is usually within the same file system. An absolute pathname includes the entire URL address, beginning with the root directory, which for a web site is usually "http://" (or "https://"), then the domain name – such as "www.yoursite.com" – and then the file directory and file name (if necessary).
NOTE: For the links you create, it is necessary to use absolute pathnames for the URL addresses in the anchor tags.
example: <a href="http://www.ballmarketing.net">
<img src="http://www.ballmarketing.net/CMD1SM_23409.gif" border="0"></a>
The actual HTML code for this image would look like this:
<a href="http://www.ballmarketing.net"> <img src="CMD1SM_23409.gif" border="0"></a>