// BEGIN ROTATING BANNER

pic_width=470;
pic_height=60;
border_size=2;
alignment=1;      /* 0=left,1=center */

if (document.images)
 {
	 pic1= new Image(pic_width,pic_height); 
     pic1.src="images/sponsors/banner-slauson.jpg";
     pic2= new Image(pic_width,pic_height); 
     pic2.src="images/sponsors/banner-superior.jpg";
     pic3= new Image(pic_width,pic_height);
     pic3.src="images/sponsors/banner-sonnax.jpg";
     pic4= new Image(pic_width,pic_height);
     pic4.src="images/sponsors/banner-vbpro.jpg";
     pic5= new Image(pic_width,pic_height); 
     pic5.src="images/sponsors/banner-ttk.jpg";
     pic6= new Image(pic_width,pic_height); 
     pic6.src="images/sponsors/banner-tcra.jpg";
     pic7= new Image(pic_width,pic_height); 
     pic7.src="images/sponsors/banner-precision.jpg";
	 pic8= new Image(pic_width,pic_height); 
     pic8.src="images/sponsors/banner-raybestos.gif";
	 pic9= new Image(pic_width,pic_height); 
     pic9.src="images/sponsors/banner-adaptacase.jpg";
	 pic10= new Image(pic_width,pic_height); 
     pic10.src="images/sponsors/banner-rostra.jpg";
	 pic11= new Image(pic_width,pic_height); 
     pic11.src="images/sponsors/banner-pdq.jpg";
	 pic12= new Image(pic_width,pic_height); 
     pic12.src="images/sponsors/banner-solpro.jpg";
	 pic13= new Image(pic_width,pic_height); 
     pic13.src="images/sponsors/banner-transtar.jpg";
	 pic14= new Image(pic_width,pic_height); 
     pic14.src="images/sponsors/banner-nobull.jpg";
	 pic15= new Image(pic_width,pic_height); 
     pic15.src="images/sponsors/banner-jerrys.jpg";
	 pic16= new Image(pic_width,pic_height); 
     pic16.src="images/sponsors/banner-lubegard.jpg";
	 pic17= new Image(pic_width,pic_height); 
     pic17.src="images/sponsors/banner-gtec.jpg";
// NewSponsorPic
 }    

urlad1="http://www.slauson.com/";
urlad2="http://www.superior-transmission.com/";
urlad3="http://sonnax.com/";
urlad4="http://valvebodypros.com/";
urlad5="http://www.sealaftermarketproducts.com";
urlad6="http://www.tcraonline.com/";
urlad7="http://www.gopnh.com/";
urlad8="http://www.raybestospowertrain.com/";
urlad9="http://www.adaptacase.com/";
urlad10="http://www.rostratransmission.com/";
urlad11="http://www.pdqparts.com/";
urlad12="http://www.solenoidpro.com/index.html";
urlad13="http://www.transtar1.com/";
urlad14="http://www.trnw.net/estore/catalog/index.php?cPath=21";
urlad15="http://www.trnw.net/jerrys/";
urlad16="http://www.lubegard.com/";
urlad17="http://www.g-tec.com/";
// NewponsorUrl

if (alignment==1)
 {
  cent_it="<CENTER>";
  cent_it2="<\/CENTER>";
 }
else
 {
  cent_it="";
  cent_it2="";
 }
 
function get_random(maxNum)
{
  if (Math.random && Math.round)
  {
    var ranNum= Math.round(Math.random()*(maxNum-1));
    ranNum+=1;
    return ranNum;
  }
  else
  {
  today= new Date();
  hours= today.getHours();
  mins=   today.getMinutes();
  secn=  today.getSeconds();
  if (hours==19)
   hours=18;
  var ranNum= (((hours+1)*(mins+1)*secn)%maxNum)+1;
  return ranNum;
  }
}

function get_Image()
{
 if (document.images)
 {
  var choose_one= get_random(17);  
  choose_one--;

  var pics= new Array(17) 
   pics[0]=pic1.src;
   pics[1]=pic2.src;
   pics[2]=pic3.src;
   pics[3]=pic4.src;
   pics[4]=pic5.src; 
   pics[5]=pic6.src;
   pics[6]=pic7.src;
   pics[7]=pic8.src;
   pics[8]=pic9.src;
   pics[9]=pic10.src;
   pics[10]=pic11.src;
   pics[11]=pic12.src;
   pics[12]=pic13.src;
   pics[13]=pic14.src;
   pics[14]=pic15.src;
   pics[15]=pic16.src;
   pics[16]=pic17.src;
//newArray

  var aurl= new Array(17)
  aurl[0]=urlad1;
  aurl[1]=urlad2;
  aurl[2]=urlad3;
  aurl[3]=urlad4;
  aurl[4]=urlad5;
  aurl[5]=urlad6;
  aurl[6]=urlad7;
  aurl[7]=urlad8;
  aurl[8]=urlad9;
  aurl[9]=urlad10;
  aurl[10]=urlad11;
  aurl[11]=urlad12;
  aurl[12]=urlad13;
  aurl[13]=urlad14;
  aurl[14]=urlad15;
  aurl[15]=urlad16;
  aurl[16]=urlad17;
//newUrl

  document.write(cent_it+"<A HREF='"+aurl[choose_one]+"'><IMG SRC='"+pics[choose_one]+"' width='"+pic_width+"' height='"+pic_height+"' border='"+border_size+"'></a>"+cent_it2);
 }
}


// BEGIN ROTATING IMAGES

var theImages = new Array() 
theImages[0] = 'images/new/rotate/0.jpg'
theImages[1] = 'images/new/rotate/1.jpg'
theImages[2] = 'images/new/rotate/2.jpg'
theImages[3] = 'images/new/rotate/3.jpg'
theImages[4] = 'images/new/rotate/4.jpg'
theImages[5] = 'images/new/rotate/5.jpg'
theImages[6] = 'images/new/rotate/6.jpg'
theImages[7] = 'images/new/rotate/7.jpg'
theImages[8] = 'images/new/rotate/8.jpg'
theImages[9] = 'images/new/rotate/9.jpg'
theImages[10] = 'images/new/rotate/10.jpg'
theImages[11] = 'images/new/rotate/11.jpg'
theImages[12] = 'images/new/rotate/12.jpg'
theImages[13] = 'images/new/rotate/13.jpg'

var j = 0
var p = theImages.length;
var preBuffer = new Array()
for (i = 0; i < p; i++){
   preBuffer[i] = new Image()
   preBuffer[i].src = theImages[i]
}
var whichImage = Math.round(Math.random()*(p-1));
function showImage(){
document.write('<img src="'+theImages[whichImage]+'">');
}



// SEARCH ENGINE CODE

function check_search(f){
	if(f.term.value.length < 1){
		alert("Please enter some text to search for");
		f.term.focus();
		return (false);
	}
}


// SPONSOR BOXES

function openBox(id) {
mainTable.className="behind1";
	if (document.all)
	document.getElementById("sponsor" + id).className="front" + id + "a";
	else
	document.getElementById("sponsor" + id).className="front" + id;
}
function closeBox(id) {
document.getElementById("sponsor" + id).className="hide";
mainTable.className="pageBody";
}
function displaySponsorBoxes() {
document.write("	<img src=\"images/sponsors/box-ttk.jpg\" width=220 height=200 border=0 ALIGN=\"MIDDLE\" alt=\"transmission rebuilders network\" ID=\"sponsor1\" class=\"hide\">");
document.write("	<img src=\"images/sponsors/box-superior.jpg\" width=220 height=200 border=0 ALIGN=\"MIDDLE\" alt=\"transmission rebuilders network\" ID=\"sponsor2\" class=\"hide\">");
document.write("	<img src=\"images/sponsors/box-sonnax.jpg\" width=220 height=200 border=0 ALIGN=\"MIDDLE\" alt=\"transmission problems\" ID=\"sponsor3\" class=\"hide\">");
document.write("	<img src=\"images/sponsors/box-vbpro.jpg\" width=220 height=200 border=0 ALIGN=\"MIDDLE\" alt=\"transmission rebuilders network\" ID=\"sponsor4\" class=\"hide\">");
document.write("	<img src=\"images/sponsors/box-tcra.jpg\" width=220 height=200 border=0 ALIGN=\"MIDDLE\" alt=\"transmission rebuilding tips\" ID=\"sponsor5\" class=\"hide\">");
document.write("	<img src=\"images/sponsors/box-precision.jpg\" width=220 height=200 border=0 ALIGN=\"MIDDLE\" alt=\"transmission rebuilders network\" ID=\"sponsor6\" class=\"hide\">");
document.write("	<img src=\"images/sponsors/box-raybestos.jpg\" width=220 height=200 border=0 ALIGN=\"MIDDLE\" alt=\"transmission troubleshooting\" ID=\"sponsor7\" class=\"hide\">");
document.write("	<img src=\"images/sponsors/box-adaptacase.jpg\" width=220 height=200 border=0 ALIGN=\"MIDDLE\" alt=\"transmission help\" ID=\"sponsor8\" class=\"hide\">");
document.write("	<img src=\"images/sponsors/box-pdq.jpg\" width=220 height=200 border=0 ALIGN=\"MIDDLE\" alt=\"transmission rebuilders network\" ID=\"sponsor9\" class=\"hide\">");
document.write("	<img src=\"images/sponsors/box-solpro.jpg\" width=220 height=200 border=0 ALIGN=\"MIDDLE\" alt=\"transmission rebuilding help\" ID=\"sponsor10\" class=\"hide\">");
document.write("	<img src=\"images/sponsors/box-transtar.jpg\" width=220 height=200 border=0 ALIGN=\"MIDDLE\" alt=\"transmission rebuilder information\" ID=\"sponsor11\" class=\"hide\">");
document.write("	<img src=\"images/sponsors/box-nobulll.jpg\" width=220 height=200 border=0 ALIGN=\"MIDDLE\" alt=\"transmission special tools\" ID=\"sponsor12\" class=\"hide\">");
document.write("	<img src=\"images/sponsors/box-rostra.jpg\" width=220 height=200 border=0 ALIGN=\"MIDDLE\" alt=\"transmission rebuilding tips\" ID=\"sponsor13\" class=\"hide\">");
document.write("	<img src=\"images/sponsors/box-jerrys.jpg\" width=220 height=200 border=0 ALIGN=\"MIDDLE\" alt=\"transmission rebuilders network\" ID=\"sponsor14\" class=\"hide\">");
document.write("	<img src=\"images/sponsors/box-lubegard.jpg\" width=220 height=200 border=0 ALIGN=\"MIDDLE\" alt=\"transmission rebuilding help\" ID=\"sponsor15\" class=\"hide\">");
document.write("	<img src=\"images/sponsors/box-gtec.jpg\" width=220 height=200 border=0 ALIGN=\"MIDDLE\" alt=\"transmission repair help\" ID=\"sponsor16\" class=\"hide\">");
document.write("	<img src=\"images/sponsors/box-slauson.jpg\" width=220 height=200 border=0 ALIGN=\"MIDDLE\" alt=\"transmission forum\" ID=\"sponsor17\" class=\"hide\">");
document.write("	<img src=\"images/sponsors/box-ttd.jpg\" width=220 height=200 border=0 ALIGN=\"MIDDLE\" alt=\"transmission rebuilding help\" ID=\"sponsor18\" class=\"hide\">");
document.write("	<img src=\"images/sponsors/box-transteam.jpg\" width=220 height=200 border=0 ALIGN=\"MIDDLE\" alt=\"transmission message board\" ID=\"sponsor19\" class=\"hide\">");
}
function displaySponsorLogos() {
document.write("	<a href=\"http://www.sealaftermarketproducts.com/\" target=\"_blank\" onMouseOver=\"openBox(1)\" onMouseOut=\"closeBox(1)\"><img src=\"images/sponsors/thumb_ttk.jpg\" width=80 height=79 vspace=5 border=2 alt=\"Click here to visit the Seal Aftermarket Products website\"></a>");
document.write("	<a href=\"http://www.superior-transmission.com/\" target=\"_blank\" onMouseOver=\"openBox(2)\" onMouseOut=\"closeBox(2)\"><img src=\"images/sponsors/thumb_superior.jpg\" width=80 height=79 vspace=5 border=2 alt=\"Click here to visit the Superior website\"></a>");
document.write("	<a href=\"http://www.sonnax.com/\" target=\"_blank\" onMouseOver=\"openBox(3)\" onMouseOut=\"closeBox(3)\"><img src=\"images/sponsors/thumb_sonnax.jpg\" width=80 height=79 vspace=5 border=2 alt=\"Click here to visit the Sonnax website\"></a>");
document.write("	<a href=\"http://www.valvebodypros.com/\" target=\"_blank\" onMouseOver=\"openBox(4)\" onMouseOut=\"closeBox(4)\"><img src=\"images/sponsors/thumb_vbpro.jpg\" width=80 height=79 vspace=5 border=2 alt=\"Click here to visit the Valve Body Pro website\"></a>");
document.write("	<a href=\"http://www.tcraonline.com/\" target=\"_blank\" onMouseOver=\"openBox(5)\" onMouseOut=\"closeBox(5)\"><img src=\"images/sponsors/thumb_tcra.jpg\" width=80 height=79 vspace=5 border=2 alt=\"Click here to visit the TCRA website\"></a>");
document.write("	<a href=\"http://www.gopnh.com/\" target=\"_blank\" onMouseOver=\"openBox(6)\" onMouseOut=\"closeBox(6)\"><img src=\"images/sponsors/thumb_precision.jpg\" width=80 height=79 vspace=5 border=2 alt=\"Click here to visit the Precision of New Hampton website\"></a>");
document.write("	<a href=\"http://www.raybestospowertrain.com/\" target=\"_blank\" onMouseOver=\"openBox(7)\" onMouseOut=\"closeBox(7)\"><img src=\"images/sponsors/thumb_raybestos.jpg\" width=80 height=79 vspace=5 border=2 alt=\"Click here to visit the Raybestor Powertrain website\"></a>");
document.write("	<a href=\"http://www.adapt-a-case.com/\" target=\"_blank\" onMouseOver=\"openBox(8)\" onMouseOut=\"closeBox(8)\"><img src=\"images/sponsors/thumb_adaptacase.jpg\" width=80 height=79 vspace=5 border=2 alt=\"Click here to visit the Adapt-A-Case website\"></a>");
document.write("	<a href=\"http://www.pdqparts.com/\" target=\"_blank\" onMouseOver=\"openBox(9)\" onMouseOut=\"closeBox(9)\"><img src=\"images/sponsors/thumb_pdq.jpg\" width=80 height=79 vspace=5 border=2 alt=\"Click here to visit the PDQ website\"></a>");
document.write("	<a href=\"http://www.solenoidpro.com/\" target=\"_blank\" onMouseOver=\"openBox(10)\" onMouseOut=\"closeBox(10)\"><img src=\"images/sponsors/thumb_solpro.jpg\" width=80 height=79 vspace=5 border=2 alt=\"Click here to visit the Solenoid Pro website\"></a>");
document.write("	<a href=\"http://transtar1.com/\" target=\"_blank\" onMouseOver=\"openBox(11)\" onMouseOut=\"closeBox(11)\"><img src=\"images/sponsors/thumb_transtar.jpg\" width=80 height=79 vspace=5 border=2 alt=\"Click here to visit the Transtar website\"></a>");
document.write("	<a href=\"http://www.trnw.net/estore/catalog/index.php?cPath=21\" target=\"_blank\" onMouseOver=\"openBox(12)\" onMouseOut=\"closeBox(12)\"><img src=\"images/sponsors/thumb_nobulll.jpg\" width=80 height=79 vspace=5 border=2 alt=\"Click here to visit the No Bull website\"></a>");
document.write("	<a href=\"http://www.rostratransmission.com/\" target=\"_blank\" onMouseOver=\"openBox(13)\" onMouseOut=\"closeBox(13)\"><img src=\"images/sponsors/thumb_rostra.jpg\" width=80 height=79 vspace=5 border=2 alt=\"Click here to visit the Rostra website\"></a>");
document.write("	<a href=\"http://www.trnw.net/jerrys/\" target=\"_blank\" onMouseOver=\"openBox(14)\" onMouseOut=\"closeBox(14)\"><img src=\"images/sponsors/thumb_jerrys.jpg\" width=80 height=79 vspace=5 border=2 alt=\"Click here to visit the Jerry's Transmission Parts website\"></a>");
document.write("	<a href=\"http://www.lubegard.com/\" target=\"_blank\" onMouseOver=\"openBox(15)\" onMouseOut=\"closeBox(15)\"><img src=\"images/sponsors/thumb_lubegard.jpg\" width=80 height=79 vspace=5 border=2 alt=\"Click here to visit the Lubegard website\"></a>");
document.write("	<a href=\"http://www.g-tec.com/\" target=\"_blank\" onMouseOver=\"openBox(16)\" onMouseOut=\"closeBox(16)\"><img src=\"images/sponsors/thumb_gtec.jpg\" width=80 height=79 vspace=5 border=2 alt=\"Click here to visit the G-Tec website\"></a>");
document.write("	<a href=\"http://www.slauson.com/\" target=\"_blank\" onMouseOver=\"openBox(17)\" onMouseOut=\"closeBox(17)\"><img src=\"images/sponsors/thumb_slauson.jpg\" width=80 height=79 vspace=5 border=2 alt=\"Click here to visit the Slauson website\"></a>");
document.write("	<a href=\"http://transtechdiag.com/\" target=\"_blank\" onMouseOver=\"openBox(18)\" onMouseOut=\"closeBox(18)\"><img src=\"images/sponsors/thumb_ttd.jpg\" width=80 height=79 vspace=5 border=2 alt=\"Click here to visit the TransTech Diagnostics website\"></a>");
document.write("	<a href=\"http://transteam.com/\" target=\"_blank\" onMouseOver=\"openBox(19)\" onMouseOut=\"closeBox(19)\"><img src=\"images/sponsors/thumb_transteam.jpg\" width=80 height=79 vspace=5 border=2 alt=\"Click here to visit the TransTeam website\"></a>");
document.write("	<a href=\"form_sponsor_info.html\"><img src=\"images/sponsors/thumb_ad.jpg\" width=80 height=79 vspace=5 border=2 alt=\"Click here to learn more about becoming a TRNW sponsor\"></a>");
}


// DISPLAY TODAY'S DATE

function displayDate() {
today = new Date();
day = today.getDate();
month1 = today.getMonth();
month1++;
year = today.getFullYear();
if (month1 == 1) { month = "January"; } 
else if (month1 == 2) { month = "February"; } 
else if (month1 == 3) { month = "March"; } 
else if (month1 == 4) { month = "April"; } 
else if (month1 == 5) { month = "May"; } 
else if (month1 == 6) { month = "June"; } 
else if (month1 == 7) { month = "July"; } 
else if (month1 == 8) { month = "August"; } 
else if (month1 == 9) { month = "September"; } 
else if (month1 == 10) { month = "October"; } 
else if (month1 == 11) { month = "November"; } 
else if (month1 == 12) { month = "December"; } 
else { month = month1; }
document.write(month + " " + day + ", " + year);
}


function displayCopyright() {
document.write("<p>Copyright &copy; 2007-2011");
}
