function browser_name() {
		var browser_name = navigator.appName;
		return browser_name;
	}

	function browser_version() {
		var browser_version = parseFloat(navigator.appVersion);
		return browser_version;
	}

	function browser_os() {
		if(navigator.appVersion.indexOf("Win95") > 0) return "WIN95";
		else if(navigator.appVersion.indexOf("Win16") > 0) return "WIN31";
		else if(navigator.appVersion.indexOf("WinNT") > 0) return "NT";
		else if(navigator.appVersion.indexOf("Mac") > 0) return "MAC";
		else if(navigator.appVersion.indexOf("UNIX") > 0) return "UNIX";
		else return "UNKNOWN";
	}

var browserOk = false;

if (browser_name() == "Netscape" && browser_version() >= 3.0) browserOk = true;
else if (browser_name() == "Microsoft Internet Explorer" && browser_version() >= 3.0) browserOk = true;

function chg_button(titlename, onoff) 
{

 if (browserOk == true) {
		if (onoff == "on") {
			document[titlename].src = "images/button_" + titlename + "_on.gif";
		}
		else
		{
			document[titlename].src = "images/button_" + titlename + "_off.gif";
		}
	}
}

function chg_img(titlename, onoff) 
{

 if (browserOk == true) {
		if (onoff == "on") {
			document[titlename].src = "images/button_" + titlename + "_on.gif";
		}
		else
		{
			document[titlename].src = "images/button_" + titlename + "_off.gif";
		}
	}
}

function chg_button_jpg(titlename, onoff) 
{

 if (browserOk == true) {
		if (onoff == "on") {
			document[titlename].src = "/images/button_" + titlename + "_on.jpg"
		}
		else
		{
			document[titlename].src = "/images/button_" + titlename + "_off.jpg";
		}
	}
}

function small_chg(titlename, onoff) 
{

 if (browserOk == true) {
		if (onoff == "on") {
			document[titlename].src = "/images/block_small_on.gif"
		}
		else
		{
			document[titlename].src = "/images/block_small_off.gif";
		}
	}
}

function chg_home(onoff) {

 if (browserOk == true) {
			document.home.src = "/images/button_home_" + onoff + ".jpg";
	}
}


function chg_tab(titlename, onoff) 
{

 if (browserOk == true) {
		if (onoff == "on") {
			document[titlename].src = "/images/tab_" + titlename + "_on.gif"
		}
		else
		{
			document[titlename].src = "/images/tab_" + titlename + "_off.gif";
		}
	}
}

function makeArray(n){
  this.length = n;
  for (i=1;i<=n;i++){
    this[i]=0;
  }
  return this;
}

function displayDate() {
  var this_month = new makeArray(12);
    this_month[0]  = "January";
    this_month[1]  = "February";
    this_month[2]  = "March";
    this_month[3]  = "April";
    this_month[4]  = "May";
    this_month[5]  = "June";
    this_month[6]  = "July";
    this_month[7]  = "August";
    this_month[8]  = "September";
    this_month[9]  = "October";
    this_month[10] = "November";
    this_month[11] = "December";
  var today = new Date();
  var day   = today.getDate();
  var month = today.getMonth();
  var year  = today.getFullYear();
  document.write(this_month[month]+" "+day+", "+year);
}

function open_image (imagefile) {

date = new Date();
counter = Math.floor((date.getSeconds()/60)*100);


	new_window = window.open (imagefile,"a" + counter + "a","width=640,height=450,toolbar=no,location=no,scrollbars=yes,directories=no,menubar=no,resizable=yes");
}

function insert_testimonial() {

var testimonial = new Array();
var author = new Array();

counter = 0;

testimonial[counter] = "Columbus Locksmith was fast and reliable when I locked myself out of my home.";
author[counter] = "";
counter++;

testimonial[counter] = "Excellent response time when I found myself in a pinch!";
author[counter] = "";
counter++;

testimonial[counter] = "Clean service--after installing my locks, Frank made sure there was no mess left behind.";
author[counter] = "";
counter++;

testimonial[counter] = "Very professional service.  I would definitely use them again.";
author[counter] = "";
counter++;

testimonial[counter] = "I know I can trust Columbus Locksmith to get the job done when I need them.";
author[counter] = "";
counter++;

testimonial[counter] = "Columbus Locksmith answered all of my questions and gave me good advice.";
author[counter] = "";
counter++;

testimonial[counter] = "I no longer have to deal with heavy, awkward keys, thanks to Columbus Locksmith.";
author[counter] = "";
counter++;

date = new Date();
pick=Math.floor((date.getSeconds()/60)*testimonial.length);

document.write('\"' + testimonial[pick] + '\" ' + author[pick])
}


function open_image (imagefile) {

date = new Date();
counter = Math.floor((date.getSeconds()/60)*100);


	new_window = window.open (imagefile,"a" + counter + "a","width=550,height=450,toolbar=no,location=no,scrollbars=yes,directories=no,menubar=no,resizable=yes");
}
