// JavaScript Document

// Begin Page Load Code
function init(){


	if(setTab != '' && setTab!= "tab00"){
		
			document.getElementById(setTab).className = "tb-act";
		/*	switch(setTab)
			{
				case 'tab02':
					document.getElementById('sm').style.display="block";
					document.getElementById('sm-pro').style.display="block";

					break;    
				case 'tab03':
					document.getElementById('sm').style.display="block";
				  	document.getElementById('sm-cur').style.display="block";				  
			  		break;
				case 'tab04':
					document.getElementById('sm').style.display="block";
				  	document.getElementById('sm-acad').style.display="block";				  
			  		break;		
						
				default:
			}
	*/
	}

}
// End Page Load Code
// Begin Search Code
function SearchKind()
{
	var rad_val = "";	
	for (var i=0; i < 2; i++)
   	{
   		if (document.searchform.Kind[i].checked)
      	{
      		rad_val = document.searchform.Kind[i].value;
      	}
   }
	
	
  if(rad_val == 'TROY')
  { 
	document.sitesearch.q.value = document.searchform.query.value;
	document.forms["sitesearch"].submit();
	return false;
  
  }
  else
  if(rad_val == 'Directory')
  {
	   
   	document.dsearch.lastname.value = document.searchform.query.value;
	document.forms["dsearch"].submit();
	return false;

	}

}
// End Search Code
// Begin Text Only Code
function textOnly(){
	document.write('<a href="http://assistive.usablenet.com/tt/');
	document.write(document.URL + '">Text Only</a>');
}
// End Text Only Code
// Begin Rotating Photo Code
function image() {
};
image = new image();
number = 0;
image[number++] = "<div id='rcontainer'><div id='rcaption'>Dr. Jack Hawkins, Jr., Chancellor</div></div><img src='http://pacific.troy.edu/images/rotating/01-pacific.png' width='317' height='113' id='photo-rotating' alt='TROY'>"
image[number++] = "<div id='rcontainer2'><div id='rcaption'>Troy University is ranked the seventh most popular educational institution among military personnel.</div></div><img src='http://pacific.troy.edu/images/rotating/02-pacific.png' width='317' height='113' id='photo-rotating' alt='TROY'>"
image[number++] = "<div id='rcontainer2'><div id='rcaption'>TROY students enjoy options in how they study - in the classroom, online or a mixture of both.</div></div><img src='http://pacific.troy.edu/images/rotating/03-pacific.png' width='317' height='113' id='photo-rotating' alt='TROY'>"
image[number++] = "<div id='rcontainer2'><div id='rcaption'>Troy University has an enrollment of more than 30,000 students worldwide</div></div><img src='http://pacific.troy.edu/images/rotating/04-pacific.png' width='317' height='113' id='photo-rotating' alt='TROY'>"
image[number++] = "<div id='rcontainer2'><div id='rcaption'>Troy University has been named as a 'Military Friendly' university by G.I. Jobs</div></div><img src='http://pacific.troy.edu/images/rotating/05-pacific.png' width='317' height='113' id='photo-rotating' alt='TROY'>"
image[number++] = "<div id='rcontainer'><div id='rcaption'>Troy University offers more than 70 majors.</div></div><img src='http://pacific.troy.edu/images/rotating/06-pacific.png' width='317' height='113' id='photo-rotating' alt='TROY'>"
increment = Math.floor(Math.random() * number);
// End Rotating Photo Code
// Google Search Code
function Google01(){
	var gaJsHost = (("https:" == document.location.protocol) ? "https://ssl." : "http://www.");
document.write(unescape("%3Cscript src='" + gaJsHost + "google-analytics.com/ga.js' type='text/javascript'%3E%3C/script%3E"));

}
function Google02(){
try {
var pageTracker = _gat._getTracker("UA-2087404-11");
pageTracker._trackPageview();
} catch(err) {}	
}
// End Google Search Code
window.onload = init;