//<![CDATA[

  // alterError - fixes a rounding bug in Netscape 2

  function alterError(value) {

    if (value<=0.99) {

  newPounds = '0';

  } else {

  newPounds = parseInt(value);

  }

  newPence = parseInt((value+.0008 - newPounds)* 100);

  if (eval(newPence) <= 9) newPence='0'+newPence;

  newString = newPounds + '.' + newPence;

  return (newString);

  }

  // buyItem - adds an item to the shooping basket

  function buyItem(newNumber, newName, newPrice) {

  if (confirm('Add '+newName+' to basket')) {

  index = document.cookie.indexOf("TheBasket");

  countbegin = (document.cookie.indexOf("=", index) + 1);

    countend = document.cookie.indexOf(";", index);

    if (countend == -1) {

     countend = document.cookie.length;

    }

     document.cookie="TheBasket="+document.cookie.substring(countbegin, countend)+"["+newNumber+"|"+newName+"|"+newPrice+"]";

  }

  }

  function changePages(firstURL){

  parent.main.location.href=firstURL;

  

}  // resetShoppingBasket - resets to shopping basket to empty

  function resetShoppingBasket() {

  index = document.cookie.indexOf("TheBasket");

  document.cookie="TheBasket=.";

  }

function WriteGraphic(x) {

  //var sObject = document.DocumentForm.GrphFile.value

  var yObject= x + ".htm"

  var newWin=window.open(yObject,"yObject",'toolbar=0,location=,directories=0,status=0,menubar=0,scrollbars=1,resizable=0,width=400,height=500');
  newWin.moveTo(400,0);
}

function WriteGraphic2(x) {

  //var sObject = document.DocumentForm.GrphFile.value

  var yObject= x + ".htm"

  var newWin2=window.open(yObject,"yObject",'toolbar=0,location=,directories=0,status=0,menubar=0,scrollbars=1,resizable=0,width=300,height=450');
  newWin2.moveTo(100,0);
}

//]]>