details = new Array()
details[0] = "Indented Bills of Materials;Inventory Control;Welding, Fabrication and Assembly;"
details[0] = details[0]	+"Process Routing;Quality Control;Materials Handeling"
details[1] = "Shipping and Receiving;Materials Inspection;Serial Number and Lot Control;"
details[1] = details[1] +"Order Processing;Inventory Control"
details[2] = "Field Supervision;Site Engineering;Project Management;Resource Planning;Scheduling"
details[3] = "Structural Analysis and Design;Arrangement and Detail Drawings;Subcontract Management;Procurement;Custom Equipment Design"
details[4] = "Facility Improvement and Expansion;Productivity Improvements;Reducing Employee Fatigue"
details[5] = "Agency Sales;Sales Support (inside and outside);Presentation Graphics;Web Site Applications;Brochures and Sales Tools"
details[6] = "Database Design and Integration;Custom Software Design;MS Office Suite Training;Invoicing and Quotations;Shop Release Packages;"
details[6] = details[6] + " Data Entry Streamlineing;Eliminating Duplication"

var a
var lenofarray
var timer2
count2 = 0			
oldcolor = "#FFFFFF"
clickid = "Home"




function highlite(o){
	if(o != clickid){
		var obj = document.getElementById(o)
		 oldcolor = obj.color
		obj.color= "#FF00FF"
		
		}
		
}
function normal(o){
	if(o != clickid){
	var obj = document.getElementById(o)
	obj.color = oldcolor
	}
}

function selectlayer(p){
	clearTimeout(timer2)
	document.getElementById("banner").style.visibility = "hidden"
	document.getElementById(clickid).color = "#FFFFFF"
	clickid = p
	if(p == "Home"){
		document.getElementById("Aboutuslay").style.visibility = "hidden"
		document.getElementById("Contactlay").style.visibility = "hidden"
		document.getElementById("Contactlay2").style.visibility = "hidden"
		document.getElementById("Serviceslay").style.visibility = "hidden"
		document.getElementById("Guaranteelay").style.visibility = "hidden"
		document.getElementById("Homelay").style.visibility = "visible"
		document.getElementById(p).color = "#FFF00"
		document.getElementById("banner").style.visibility = "visible"
		thetest()
		}
	if(p == "About Us"){
		document.getElementById("Aboutuslay").style.visibility = "visible"
		document.getElementById("Contactlay").style.visibility = "hidden"
		document.getElementById("Contactlay2").style.visibility = "hidden"
		document.getElementById("Serviceslay").style.visibility = "hidden"
		document.getElementById("Guaranteelay").style.visibility = "hidden"
		document.getElementById("Homelay").style.visibility = "hidden"
		document.getElementById(p).color = "#FFFF00"
		}
	if(p == "Contact"){
		document.getElementById("Aboutuslay").style.visibility = "hidden"
		document.getElementById("Contactlay").style.visibility = "visible"
		document.getElementById("Contactlay2").style.visibility = "visible"
		document.getElementById("Serviceslay").style.visibility = "hidden"
		document.getElementById("Guaranteelay").style.visibility = "hidden"
		document.getElementById("Homelay").style.visibility = "hidden"
		document.getElementById(p).color = "#FFFF00"
		}
	if(p == "Services"){
		document.getElementById("Aboutuslay").style.visibility = "hidden"
		document.getElementById("Contactlay").style.visibility = "hidden"
		document.getElementById("Contactlay2").style.visibility = "hidden"
		document.getElementById("Serviceslay").style.visibility = "visible"
		document.getElementById("Guaranteelay").style.visibility = "hidden"
		document.getElementById("Homelay").style.visibility = "hidden"
		document.getElementById(p).color = "#FFFF00"
		}
	if(p == "Guarantee"){
		document.getElementById("Aboutuslay").style.visibility = "hidden"
		document.getElementById("Contactlay").style.visibility = "hidden"
		document.getElementById("Contactlay2").style.visibility = "hidden"
		document.getElementById("Serviceslay").style.visibility = "hidden"
		document.getElementById("Guaranteelay").style.visibility = "visible"
		document.getElementById("Homelay").style.visibility = "hidden"
		document.getElementById(p).color = "#FFFF00"
		}
}



function SetLayers(){
var a=arguments
for(i=1; i<a.length; i+=2){
	x=i+1
	elem = FP_getObjectByID(a[i])
	elem.style.visibility=a[x]
	}
if(a[0] == "img1"){
	SwapImg(a[0],2,"img2",3,"img3",6)
}else{
	if(a[0] == "img2"){
	SwapImg(a[0],5,"img1",0,"img3",6)
	}else{
	if(a[0] == "img3"){
	SwapImg(a[0],8,"img1",0,"img2",3)
	}else{
	document.images["img1"].src=imgsource[0].src
	}}}
}

function showdetails(id){
	thestuff.style.visibility = "visible"
	a = id
	count2 = count2+1
	var splitdetail = details[a].split(";")
	if(count2>splitdetail.length){
	
		clearTimeout(timer2)
	}else{
		
		var newell = document.createElement("p")
		newell.style.fontSize = "12"
		newell.style.fontFamily = "arial"
		newell.style.marginBottom = "-10"
		var newtext = document.createTextNode(splitdetail[count2-1])
		newell.appendChild(newtext)
		var detaillay = document.getElementById("usdetails")
		detaillay.appendChild(newell)
		timer2 = setTimeout("showdetails(a)", 200);
	  }
}



function getDTpage(){
	if(window.screen.width < 1024){
	alert("This Link is Best Viewed with a Browser Setting of 1024 x 768")}
	TimeLine = open("TimeLine.htm")
}
function getDBpage(){
	DataBase = window.open("DataBase.htm")
}




var nDots = 9;
var Xpos = 0;
var Ypos = 0;

var DELTAT = .01;
var SEGLEN = 10;
var SPRINGK = 10;
var MASS = 1;
var GRAVITY = 50;
var RESISTANCE = 10;
var STOPVEL = 0.1;
var STOPACC = 0.1;
var DOTSIZE = 11;
var BOUNCE = 0.75;
var isNetscape = navigator.appName=="Netscape";
var followmouse = true;
var dots = new Array();

function init() {
if(dotson =="on"){
var i = 0;
for (i = 0; i < nDots; i++) {
dots[i] = new dot(i);
}
if (!isNetscape) {
// I only know how to read the locations of the 
// <LI> items in IE
//skip this for now
// setInitPositions(dots)
}
for (i = 0; i < nDots; i++) {
dots[i].obj.left = dots[i].X;
dots[i].obj.top = dots[i].Y;
}
if (isNetscape) {
startanimate();
} else {
// let dots sit there for a few seconds
// since they're hiding on the real bullets
thetimer=setTimeout("startanimate()", 1000);
   }
 }else{clearTimeout(thetimer)
 		clearInterval(theinterval)
 		for(var t = 1;t<9;++t){
 		     document.getElementById("dot"+t).style.top = "5"
 		     document.getElementById("dot"+t).style.left = "5"} 
 		  } 
}
function dot(i) {
this.X = Xpos;
this.Y = Ypos;
this.dx = 0;
this.dy = 0;
if (isNetscape) {	
this.obj = eval("document.dot" + i);
} else {
this.obj = eval("dot" + i + ".style");
   }
}
function startanimate() {	
theinterval=setInterval("animate()", 20);
}
function setInitPositions(dots) {
var startloc = document.all.tags("LI");
var i = 0;
for (i = 0; i < startloc.length && i < (nDots - 1); i++) {
dots[i+1].X = startloc[i].offsetLeft
startloc[i].offsetParent.offsetLeft - DOTSIZE;
dots[i+1].Y = startloc[i].offsetTop +
startloc[i].offsetParent.offsetTop + 2*DOTSIZE;
}
dots[0].X = dots[1].X;
dots[0].Y = dots[1].Y - SEGLEN;
}
function MoveHandler(e) {
Xpos = e.pageX;
Ypos = e.pageY;	  
return true;
}
function MoveHandlerIE() {
Xpos = window.event.x + document.body.scrollLeft;
Ypos = window.event.y + document.body.scrollTop;	  
}

function vec(X, Y)
{
this.X = X;
this.Y = Y;
}

// adds force in X and Y to spring for dot[i] on dot[j]
function springForce(i, j, spring)
{
var dx = (dots[i].X - dots[j].X);
var dy = (dots[i].Y - dots[j].Y);
var len = Math.sqrt(dx*dx + dy*dy);
if (len > SEGLEN) {
var springF = SPRINGK * (len - SEGLEN);
spring.X += (dx / len) * springF;
spring.Y += (dy / len) * springF;
   }
}
function animate() {	
var start = 0;
if (followmouse) {
dots[0].X = Xpos;
dots[0].Y = Ypos;	
start = 1;
}
for (i = start ; i < nDots; i++ ) {
var spring = new vec(0, 0);
if (i > 0) {
springForce(i-1, i, spring);
}
if (i < (nDots - 1)) {
springForce(i+1, i, spring);
}
var resist = new vec(-dots[i].dx * RESISTANCE, -dots[i].dy * RESISTANCE);
var accel = new vec((spring.X + resist.X)/ MASS, (spring.Y + resist.Y)/ MASS + GRAVITY);
dots[i].dx += (DELTAT * accel.X);
dots[i].dy += (DELTAT * accel.Y);
if (Math.abs(dots[i].dx) < STOPVEL &&
Math.abs(dots[i].dy) < STOPVEL &&
Math.abs(accel.X) < STOPACC &&
Math.abs(accel.Y) < STOPACC) {
dots[i].dx = 0;
dots[i].dy = 0;
}
dots[i].X += dots[i].dx;
dots[i].Y += dots[i].dy;
var height, width;
if (isNetscape) {
height = window.innerHeight + document.scrollTop;
width = window.innerWidth + document.scrollLeft;
} else {	
height = document.body.clientHeight + document.body.scrollTop;
width = document.body.clientWidth + document.body.scrollLeft;
}
if (dots[i].Y >=  height - DOTSIZE - 1) {
if (dots[i].dy > 0) {
dots[i].dy = BOUNCE * -dots[i].dy;
}
dots[i].Y = height - DOTSIZE - 1;
}
if (dots[i].X >= width - DOTSIZE) {
if (dots[i].dx > 0) {
dots[i].dx = BOUNCE * -dots[i].dx;
}
dots[i].X = width - DOTSIZE - 1;
}
if (dots[i].X < 0) {
if (dots[i].dx < 0) {
dots[i].dx = BOUNCE * -dots[i].dx;
}
dots[i].X = 0;
}
dots[i].obj.left = dots[i].X;			
dots[i].obj.top =  dots[i].Y;		
   }
}
var osd = "    IF REDUCING YOUR BUSINESS COSTS AND INCREASING PROFITS SOUNDS INTERESTING ..... CONTACT US TODAY!     INTEGRATING TECHNOLOGY TO MAKE YOU  MORE MONEY!     REAL SOLUTIONS THAT WORK ... WE GUARANTEE IT!     IF WE DON'T DELIVER ... YOU DON'T PAY! "
var timer;
var msg = "";
var count = 0;
function scrollMaster() {
count = 0
//msg = customDateSpring(new Date())
//clearTimeout(timer)
//msg += " " + showtime() + " " + osd
//for (var i= 0; i < 120; i++){
msg = osd
//msg = msg + " "
//}
scrollMe()
}
function scrollMe(){
//count= count+1
//if(count>249){
//clearTimeout(timer)
//scrollMaster()

//}else{

window.status = msg;
msg = msg.substring(1, msg.length) + msg.substring(0,1);
timer = setTimeout("scrollMe()", 200)

}
function showtime (){
var now = new Date();
var hours= now.getHours();
var minutes= now.getMinutes();
var seconds= now.getSeconds();
var months= now.getMonth();
var dates= now.getDate();
var years= now.getYear();
var timeValue = ""
timeValue += ((months >9) ? "" : " ")
timeValue += ((dates >9) ? "" : " ")
timeValue = ( months +1)
timeValue +="/"+ dates
timeValue +="/"+  years
var ap="A.M."
if (hours == 12) {
ap = "P.M."
}
if (hours == 0) {
hours = 12
}
if(hours >= 13){
hours -= 12;
ap="P.M."
}
var timeValue2 = " " + hours
timeValue2 += ((minutes < 10) ? ":0":":") + minutes + " " + ap
return timeValue2;
}
function MakeArray(n) {
this.length = n
return this
}
monthNames = new MakeArray(12)
monthNames[1] = "Janurary"
monthNames[2] = "February"
monthNames[3] = "March"
monthNames[4] = "April"
monthNames[5] = "May"
monthNames[6] = "June"
monthNames[7] = "July"
monthNames[8] = "August"
monthNames[9] = "Sept."
monthNames[10] = "Oct."
monthNames[11] = "Nov."
monthNames[12] = "Dec."
daysNames = new MakeArray(7)
daysNames[1] = "Sunday"
daysNames[2] = "Monday"
daysNames[3] = "Tuesday"
daysNames[4] = "Wednesday"
daysNames[5] = "Thursday"
daysNames[6] = "Friday"
daysNames[7] = "Saturday"
function customDateSpring(oneDate) {
var theDay = daysNames[oneDate.getDay() +1]
var theDate =oneDate.getDate()
var theMonth = monthNames[oneDate.getMonth() +1]
var dayth="th"
if ((theDate == 1) || (theDate == 21) || (theDate == 31)) {
dayth="st";
}
if ((theDate == 2) || (theDate ==22)) {
dayth="nd";
}
if ((theDate== 3) || (theDate  == 23)) {
dayth="rd";
}
return theDay + ", " + theMonth + " " + theDate + dayth + ","
}
// End -->
var thestuff = document.getElementById("usdetails")
function hidedetails(){
	thestuff.style.visibility = "hidden"
	clearTimeout(timer2)
	lenofarray=0
	count2=0
	var child1 = thestuff.childNodes
	var leng = child1.length
	
	for(var ch=0;ch<leng;++ch){
		deletethedetail()
	}
}
function deletethedetail(){
	
	var childrens = thestuff.firstChild
		thestuff.removeChild(thestuff.firstChild)
}

function expandWidth(){
	document.getElementById("banner").style.posWidth = Q+1}
	
var bannertxt = ""
var Q = 0
var timer2
var base = "Manufacturing - Warehousing - Construction - Engineering - Plant Layout - Sales - Office Automation - "
	
	
function thetest(){
	if(Q==-1){
	clearTimeout(timer2)
	Q = 0
	
	thetest()
	}else{document.getElementById("banner").style.posLeft = (window.screen.width - 49 - Q) 
	expandWidth()
	//document.getElementById("banner").style.posHeight = 27 
	if(Q%8==0){
	bannertxt = bannertxt + base.substring(0,1)
	base = base.substring(1,base.length) + base.substring(0,1)}
	document.getElementById("banner").innerHTML = bannertxt
	timer2 = setTimeout("thetest()",30)
	Q = Q+2}
}
	

