// This function will write out a return link on the page for the
// Home page.  If we came from the home page it will be just a JavaScript
// back function so that we return to the same spot.  If the referring
// page was not the Home page, a full URL for the Home page is written.

function display_homepage_link () {
//   alert("document.referrer=" + document.referrer);
//   alert("indexOf=" + document.referrer.indexOf("earthlink.net/~earthwalker1/index.html"));
//   alert("indexOf=" + document.referrer.indexOf("/dad.html"));

   // If we came from the Home page then just write a link with a
   // JavaScript back function.

   ref = document.referrer;
   re1 = new RegExp("earthlink.net/~earthwalker1/$");
   re2 = new RegExp("earthlink.net/~earthwalker1/index.html$");
   re3 = new RegExp("web/dad/$");
   re4 = new RegExp("/index.html$");
   if (re1.exec(ref) || re2.exec(ref) || re3.exec(ref) || re4.exec(ref))
      document.writeln('<a href="javascript:history.back()">Back to Earthwalker home page</a>');
   else
      document.writeln('<a href="http://home.earthlink.net/~earthwalker1/">Earthwalker home page</a>');
  }
