Contact me if you'd
like to advertise
in this prime spot
 CoverYourASP --> The base href tag

Free membership

Join in the fun! Sign in
Member Services

Site navigation
Download the entire site!
Search my articles
Free Magazines
Browse the directory

Send me feedback
Buy my boxer shorts

Recommend this page
Printer-friendly page

Resources I recommend
Link to my site
Advertising slashed!
About your privacy
Legal stuff
Site statistics
61 active users
350 visitors today
345 pages today
(only part of today)
Tools I use

CoverYourASP
Copyright © 1999-2009 James Shaw.
All rights reserved.

ASP.NET Blog
RSS submissions
E-commerce

Now open source with SourceForge!

Some history (if you're interested!)

I have tried various methods of maintaining the links to pages on my web site. Initially, all links were relative, not absolute, so I would use:

<a href="Hello.asp">go to my hello page</a>

instead of:

<a href="http://CoverYourASP.com/Hello.asp">go to my hello page</a>

This made it easy to move pages between my development server at home and the production server hosted by my ISP.

Unfortunately, I then had a problem with my 404 error handler when some spiders crawled the site. It's a long story, but they would cause the relative links on my pages to be applied from non-existant folders, causing an infinite loop of 404 errors!

So I then "fixed the problem" by using absolute links in the header and footer - no matter how the 404 was generated it would always show spiders the same absolute links.

But that made it difficult to use on my development machine, and yours. All the links in the header and footer pointed to the real CoverYourASP site!

Part 2: Using <base href>...

Featured sponsor
My favorite resources

Tiki Statues - Tiki Masks - Tiki Totems


CoverYourASP Mugs, T-shirts, caps - even Boxer shorts...
I don't make a penny from these, but they're a lot of fun! Don't you need a new mouse mat?


New Proposal Kit Professional 5.1
Brand yourself as a top professional: create quotes and amazing proposals and get many legal documents free!

The latter saved me 3 times the purchase price on the first day I owned it!