SEARCH W7R

Monday, April 02, 2012

HTML: Creating Links


Creating Links with HTML

Let's begin with an example of a link coded in HTML. *open in a new window to avoid leaving this page!   Open me in a new window! 
 The link above sent you to my youtube page.

Here is the HTML code I used to create the link.

 <a href="http://www.youtube.com/user/w7rdotblogspot/videos">Open me in a new window!</a>


There are 4 basic parts to this code
  1. The tags <a> and </a>       ~These are anchor tags.
  2. The attribute href       ~This is an attribute of the anchor tag.
  3. The site URL      ~Location for the site the link will take the user to
  4. Pain text       ~What the user sees on the webpage
Try running the following sample HTML text (Online HTML Compiler)
<html>
<head>
</head>
<body>
Google is a good site. Isn't it?
<a href="http://google.com"> >>Google<< </a>
</body>
</html>

No comments: