// JavaScript Document

var min=8;//minimum size that can be achieved with the text size controls
var max=18;//maximun that can be achieved with the text size controls











/////////functions


function focusSearch(id) {
	//clears value of search box on focus
	
	document.search.q.value='';
}

function blurSearch(id) {
	//resets value of search box on blur
	
	document.search.q.value='search';
	//hideSearch();
}


function hideSearch () {
	//var liveSearch = document.getElementById("livesearch");
	//liveSearch.style.display = 'none';
}

function showSearch () {
	//var liveSearch = document.getElementById("livesearch");
	//liveSearch.style.display = 'block';
}



function increaseFontSize() {
	//increases font size of <p> tags

	var p = document.getElementsByTagName('p');
   for(i=0;i<p.length;i++) {
      if(p[i].style.fontSize) {
         var s = parseInt(p[i].style.fontSize.replace("px",""));
      } else {
         var s = 12;
      }
      if(s!=max) {
         s += 1;
      }
      p[i].style.fontSize = s+"px"
   }
}
function decreaseFontSize() {
		//increases font size of <p> tags

   var p = document.getElementsByTagName('p');
   for(i=0;i<p.length;i++) {
      if(p[i].style.fontSize) {
         var s = parseInt(p[i].style.fontSize.replace("px",""));
      } else {
         var s = 12;
      }
      if(s!=min) {
         s -= 1;
      }
      p[i].style.fontSize = s+"px"
   }   
}


