

function showPic(whichpic, where) {
  if (document.getElementById) {
  	document.getElementById(where).src = "images/loading.gif"
    document.getElementById(where).src = whichpic.href
    return false
  } else {
    return true
  }
}

function swapPic(url, where) {
  if (document.getElementById) {
    document.getElementById(where).src = "images/loading.gif"
    document.getElementById(where).src = url
    return false
  } else {
    return true
  }
}

function loadXMLDoc(id, url) {
  var stateChange = function() {
      if (xmlhttp.readyState == 4) { // if xmlhttp shows "loaded"
      if (xmlhttp.status == 200) { // and if "OK"
      	document.getElementById(id).innerHTML = xmlhttp.responseText
   	  } else {
   	    // uncomment for debugging
        // alert("Problem retrieving data:" + xmlhttp.statusText
        
        // push HTML comment if there was an error
        document.getElementById(id).innerHTML = "<!-- hello -->"
  	  }
    }
  }
  if (window.XMLHttpRequest) { // code for Mozilla, etc.
    xmlhttp = new XMLHttpRequest()
    xmlhttp.onreadystatechange = stateChange
    xmlhttp.open("GET", url, true)
    xmlhttp.send(null)
  } else if (window.ActiveXObject) { // code for IE
    xmlhttp = new ActiveXObject("Microsoft.XMLHTTP")
    if (xmlhttp) {
      xmlhttp.onreadystatechange=stateChange
      xmlhttp.open("GET", url, true)
      xmlhttp.send()
    }
  }
}


function openMe(url, width, height) {
  height = height+60+50+20
  width = width+60+20
  newwindow = window.open(url, 'peterbarss', 'height='+height+',width='+width+',menubar=no,status=no,resizable=no,location=no');
  newwindow.resizeTo(width,height+10)
  //newwindow.moveTo(0,0)
  if (window.focus) {
  	newwindow.focus()
  }
  return false;
}

// -->