// JavaScript Document

function changeLocation(url,toDiv,nextLocation)
{
  loadDATA(url,toDiv);
//  alert('nextLocation is' + nextLocation);
  currLocation=nextLocation;

}

function loadDATA(url,toDiv)
{
  var xhr = createXHR(); 
  xhr.open("GET",url,false);
  xhr.send(null);
  document.getElementById(toDiv).innerHTML=xhr.responseText;
}

function showText(text,toDiv)
{
  if (!document.getElementById) {
  alert('!document.getElementById');
  return;
  }
  document.getElementById(toDiv).innerHTML=text;
}

function currentLocation()
{
  if (!document.getElementById) {
  alert('!document.getElementById');
  return;
  }
//  alert('currentLocation is' + currLocation);
  document.getElementById('textnav').innerHTML=currLocation;
}
