// JavaScript Document
<!--
function MM_swapImgRestore() { //v3.0
  var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
}

function MM_preloadImages() { //v3.0
  var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
    if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}

function MM_findObj(n, d) { //v4.01
  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
  if(!x && d.getElementById) x=d.getElementById(n); return x;
}

// Text rotator
function MM_swapImage() { //v3.0
  var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
   if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
}

var imgsa = new Array("'You’re a very professional group.' <br> \&nbsp; \&nbsp; R.K., Chief Technology Officer",
                               "'The information flow has been extremely efficient.' <br> \&nbsp; \&nbsp; C.K., Firmware Engineer",
                               "'You’re the top. I’ve been doing business with you for years.' <br> \&nbsp; \&nbsp; B.B., Engineering Services Manager",
                               "'You’re extremely responsive and very professional.' <br> \&nbsp; \&nbsp; L.M., Software QA Engineer",
                               "'Awesome with communication.' <br> \&nbsp; \&nbsp; P.M., Project Manager",
                               "'I certainly appreciate the opportunity, and Summit has been fantastic so far.' <br> \&nbsp; \&nbsp; T.O., Mechanical Designer",
                               "'I really like working with you.' <br> \&nbsp; \&nbsp; L.K., Human Resources Director",
                               "'You are extremely well-organized.' <br> \&nbsp; \&nbsp; M.I., Mechanical Engineer",
                               "'I’m very, very satisfied.' <br> \&nbsp; \&nbsp; C.C., Director, Human Resources",
                               "'Your representatives are faster than your competition.' <br> \&nbsp; \&nbsp; S.D., Mechanical Designer",
                               "'You came up with resumes quickly, screened them, and the interviews showed up on time.' <br> \&nbsp; \&nbsp; M.W., Manager Automation Group",
                               "'I have never received such excellent treatment from any other recruiters.' <br> \&nbsp; \&nbsp; E.O., Manufacturing Engineer",
                               "'Excellent, responsive.' <br> \&nbsp; \&nbsp; P.D., Director of Engineering",
                               "'Very good follow-up.' <br> \&nbsp; \&nbsp; J.N., Director of Software Engineering",
                               "'You’re at the top of the four or five companies I call.' <br> \&nbsp; \&nbsp; T.M., Engineering Manager",
                               "'You got back to me in a much more timely fashion than your competition.' <br> \&nbsp; \&nbsp; D.W., Mechanical Drafter",
                               "'Summit is very attentive.' <br> \&nbsp; \&nbsp; M.P., Project Manager",
                               "'You’re very responsive and found me a position very quickly.' <br> \&nbsp; \&nbsp; J.D., Mechanical Engineer",
                               "'You’re really doing well, I’m very satisfied.' <br> \&nbsp; \&nbsp; T.L., General Manager")
var alta = new Array()
var ran_unrounded=Math.random()*19;
var ran_number=Math.floor(ran_unrounded);


var currentAda = ran_number
var imgCta = 19
function cyclea() {
  if (currentAda == imgCta) {
    currentAda = 0
  }
	 document.getElementById('adLinka').innerHTML = imgsa[currentAda]
  currentAda++
}
  window.setInterval("cyclea()",5000)
  
  
 // Comma separated list of images to rotate 
var imgs = new Array('images/home_main_1.jpg','images/home_main_2.jpg','images/home_main_3.jpg','images/home_main_4.jpg','images/home_main_5.jpg','images/home_main_6.jpg');
// delay in milliseconds between image swaps 1000 = 1 second 
var delay = 20000;
var ran_unrounded=Math.random()*5;
var ran_number=Math.floor(ran_unrounded); 
var counter = ran_number;

//function preloadImgs(){
  //for(var i=0;i<imgs.length;i++){
   // MM_preloadImages(imgs[i]);
 // }
//}

function randomImages(){
  if(counter == (imgs.length)){
    counter = 0;
  }
  MM_swapImage('bannerimg', '', imgs[counter++]);
  setTimeout('randomImages()', delay);
}


function submitform1()
{
  document.search1.submit();
}

function submitform2()
{
  document.search2.submit();
}

function submitform3()
{
  document.search3.submit();
}

function submitform4()
{
  document.search4.submit();
}
function submitform5()
{
  document.search5.submit();
}
//-->
