var allHTMLTags = new Array();

function hideAll(theClass) {

  //Create Array of All HTML Tags
  var allHTMLTags = document.getElementsByTagName("*");

  //Loop through all tags using a for loop
  for (i = 0; i < allHTMLTags.length; i++) {

    //Get all tags with the specified class name.
    if (allHTMLTags[i].className == theClass) {
      allHTMLTags[i].style.display = 'none';
    }
  }
}

//content divs

function pageContentSwitch(newPage) {
  hideAll('pageContent');
  document.getElementById(newPage).style.display = "";
}
