<!--
// Copyright © 2005 Smartech Global Solutions - www.plastemart.com - All Rights Reserved.
// This script in part or whole is not to be used without taking prior written permission from plastemart.com 

 var bName = navigator.appName;
 var bVer = parseInt(navigator.appVersion);
 var bAgent=navigator.userAgent;

 indOP=bAgent.indexOf("Opera");
  
 verOP=parseInt(bAgent.charAt(indOP+6));

 var OP = (indOP!=-1);
 var OP7 = (indOP!=-1 && verOP<8);
 var OP8 = (indOP!=-1 && verOP>=8);
 var FF = (bAgent.indexOf("Firefox")!=-1);
 indNS=bAgent.indexOf("Netscape");
 verNS=bAgent.charAt(indNS+9);
 if (!isInteger(verNS)) verNS=parseInt(bAgent.charAt(indNS+8));
 else verNS=parseInt(verNS);

 var NS = (bName == "Netscape" && indNS!=-1)
 var NS4 = (bName == "Netscape" && indNS!=-1 && verNS < 5);
 var NS6 = (bName == "Netscape" && indNS!=-1 && verNS >= 6);
 var IE9 = (bName != "Netscape" && bVer >= 4 && bAgent.indexOf("MSIE 9")!=-1 && !OP);
 var IE8 = (bName != "Netscape" && bVer >= 4 && bAgent.indexOf("MSIE 8")!=-1 && !OP);
 var IE7 = (bName != "Netscape" && bVer >= 4 && bAgent.indexOf("MSIE 7")!=-1 && !OP);
 var IE6 = (bName != "Netscape" && bVer >= 4 && bAgent.indexOf("MSIE 6")!=-1 && !OP);
 var IE5 = (bName != "Netscape" && bVer >= 4 && bAgent.indexOf("MSIE 5")!=-1 && !OP);
 var IE4 = (bName != "Netscape" && !IE5 && !IE6 && !IE7 && !IE8 && !IE9 && !OP && !FF); 

 if (NS4 || IE4) alert ("Thank You for visiting our web site! Your browser cannot view our website properly due to its inability to fully support CSS. Please upgrade it to the latest version or try viewing our pages with another browser. Thanks for your co-operation!");
 
function isInteger(s){
	var i;
    for (i = 0; i < s.length; i++){   
        var c = s.charAt(i);
		if (((c < "0") || (c > "9"))) return false;
    }
    return true;
}
// SET BACKGROUND Image 
function setBgImage(obj, bit){
	id=obj.id;
	if (bit==1){	
		if (NS6 || IE5 || IE6 || OP || FF) eval('document.getElementById("'+id+'").style.backgroundPosition="0 -28px"');
		if (IE4) eval('document.all.'+id+'.style.backgroundPosition="0 -28px"');
	}
	else {	
		if (NS6 || IE5 || IE6 || OP || FF) eval('document.getElementById("'+id+'").style.backgroundPosition="0 0"');
		if (IE4) eval('document.all.'+id+'.style.backgroundPosition="0 0"');
	}
}
var arrImg=new Array;
function preloadImages(img,i) {
  var d=document; 
  if(d.images){
    var x,iName,temp;
	if (img.indexOf(".")!=-1){
		iName=img.substring(img.lastIndexOf("/")+1,img.lastIndexOf(".")); 
		arrImg[i]=new Image; 
		arrImg[i].src=img;
		arrImg[i].name=iName;
	}
  }
}

var photos=new Array();
var iWidth=73;
//var iHeight=82;
var iHeight=70;

//Paths to Photos:
photos[0]="/images/h_pic1.jpg";
photos[1]="/images/h_pic2.jpg";
photos[2]="/images/h_pic3.jpg";
photos[3]="/images/h_pic4.jpg";
photos[4]="/images/h_pic5.jpg";
photos[5]="/images/h_pic6.jpg";
photos[6]="/images/h_pic7.jpg";

//Photo Album Functions:
function applyeffect(){
	if (document.all && photo_slideshow.filters){
		photo_slideshow.filters.revealTrans.Transition=Math.floor(Math.random()*23);
		photo_slideshow.filters.revealTrans.stop();
		photo_slideshow.filters.revealTrans.apply();
		document.images.photo_slideshow.src=arrImg[cursor].src;
		document.images.photo_slideshow.name=arrImg[cursor].name;
		photo_slideshow.filters.revealTrans.play();
	}
		document.images.photo_slideshow.src=arrImg[cursor].src;
}

function next_photo(){
	if(blnRound2==true && cursor>=iRnd) return;
	else if (cursor<photos.length-1) cursor++;
	else {
		blnRound2=true;
		cursor=0;
	}
	applyeffect();
	play_album();
}

function play_album() {
	timeOn = setTimeout("next_photo()",4000);
}

var blnRound2=false;
var cursor=0;
var iRnd=Math.floor(Math.random()*photos.length);
for (i=0;i<photos.length;i++){
	preloadImages(photos[i],i);
}

var intDivWidth=520
var intLeft=234
var intTop=120

//font color, font hilight color, background color, hilight background color
var hexFColor="#000000"
var hexFHColor="#ffffff"
var hexBgColor="#FAEBBF"
//var hexBgHColor="#6699CC"
var hexBgHColor="#296441"

function divMenu(img){
	return imgPos(img)-imgPos('services')+intLeft;
}
//-->