1. Technology

Links on Web Pages


What is a Link?:

Links are often the first thing that most developers want to learn. Links are what allow your readers to move around the Web. In fact, links put the "hyper" in "hypertext" (definition of hypertext).

Links use the a tag to connect text or images to other pages on your site or other sites altogether. Luckily, it's easy to add links to Web pages.

What is an Anchor or Bookmark?:

Anchors or bookmarks are a special type of link that points to within a page, rather than the very top. Creating bookmarks are a little bit more work than plain links, because you have to mark the location of the anchor as well as the link itself. But once you understand that, you'll know it's easy to add internal links.

How to Use Web Page Links:

You may think, I've got my a tag, what more do I need to know to use links? Well, firstly, there's how you're linking to your pages. Use absolute or relative paths to the pages.

But once you've created the link paths, you're not done. You need to create links people will click on. Free tip: people don't click on "click here". You can tell people to "click here" over and over on your site, and they still won't click. Make your links information heavy and people will be more likely to click.

Basic Uses for Links:

There are lots of things you can use links for, beyond just linking to your favorite band's website.

Link Tips and Tricks:

Styling Your Links:

Often, when people think of styling links, they only think of changing the color. But with modern browsers, you can use CSS to change much more than the color of your links. You can make your links look like buttons or boxes depending upon what CSS properties you use.

Link Rot:

But before you get too excited about creating and styling your links, you should be aware of the link "dark side": Link Rot. This happens when good links go bad. You can avoid it on your own site by forwarding links to their new location if they move.

Link Checkers:

If you have a lot of links on your site, then you'll want to use a link checker. Link checkers are a specific type of HTML validator that checks the links on your page (or sometimes your whole site) to find the broken ones. I recommend running a link checker regularly across your link collections. You would be surprised how quickly they can go bad.

  1. About.com
  2. Technology
  3. Web Design / HTML
  4. HTML and XHTML
  5. Beginning HTML Tutorials
  6. Links: Creating Links, Using Links, Styling Links, Anchors, Hyperlinks and Hrefs

©2014 About.com. All rights reserved.