<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">

<html>
<head>
        <title>Untitled</title>
<script language="JavaScript" type="text/javascript">
<!-- // swap href in links
//accepts two parameters: href of link calling swap(), and the new url to swap with.

function swap(swapHref, newHref) {
var docLinks = new Array();
  for (i=0; i < document.links.length; i++) {
   docLinks[i] = document.links[i].href;
//   alert(docLinks[i]);
  }
  for (i=0; i<docLinks.length; i++) {
    if (docLinks[i] == swapHref) {
      document.links[i].href = newHref;
//      alert(newHref);
    }
  }
}
// -->
</script>
</head>

<body>

<a href="test.html" onMouseOver="swap(this.href, 'new.html');">test</a><br><br>
<a href="test2.html" onMouseOver="swap(this.href, 'new2.html');">test2</a>
</body>
</html>