<!-- Begin hiding script from older browsers

// css matching column heights

matchHeight=function(){ 

     var divs,contDivs,maxHeight,divHeight,d; 

     // get all <div> elements in the document 

     divs=document.getElementsByTagName('div'); 

     contDivs=[]; 

     // initialize maximum height value 

     maxHeight=250; 

     // iterate over all <div> elements in the document 

     for(var i=0;i<divs.length;i++){ 

          // make collection with <div> elements with class attribute 'container' 

          if(/\bcontainer\b/.test(divs[i].className)){ 

                d=divs[i]; 

                contDivs[contDivs.length]=d; 

                // determine height for <div> element 

                if(d.offsetHeight){ 

                     divHeight=d.offsetHeight; 

                } 

                else if(d.style.pixelHeight){ 

                     divHeight=d.style.pixelHeight; 

                } 

                // calculate maximum height 

                maxHeight=Math.max(maxHeight,divHeight); 

          } 

     } 

     // assign maximum height value to all of container <div> elements 

     for(var i=0;i<contDivs.length;i++){ 

          contDivs[i].style.height=maxHeight+'px'; 

     } 

} 

// execute function when page loads 

window.onload=function(){ 

     if(document.getElementsByTagName){ 

          matchHeight(); 

     } 

} 
<!-- Begin hiding script from older browsers

// date and time........................................

function initArray() {
for(i=0;i<initArray.arguments.length; i++)
this[i] = initArray.arguments[i];}
var isnMonths=new initArray("January","February","March","April","May","June","July","August","September","October","November","December");
var isnDays= new initArray("Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday","Sunday");
today=new Date();
hrs=today.getHours();
min=today.getMinutes();
sec=today.getSeconds();
clckh=""+((hrs>12)?hrs-12:hrs); 
clckm=((min<10)?"0":"")+min;
clcks=((sec<10)?"0":"")+sec;
clck=(hrs>=12)?"p.m.":"a.m.";
var stnr="";
var ns="0123456789";
var a="";


// history window function...................................

function newWindow(){

historyWin = window.open("tour.htm", "tour", "height=255,width=400,scrollbars=no");
historyWin.focus()

}


// contest window function...................................

function tourWindow(page){

contestWin = window.open(page, "tour", "height=450,width=770,top=50,scrollbars=no");
contestWin.focus()

}



// information window function.........................................

function newWindow2(news){

leftPos = 0
if (screen) {

leftPos = screen.width-600

}
newsWin = window.open( news,  "info", "height=350,width=480,left="+ leftPos +",top=50,scrollbars=yes");
newsWin.focus()
}



// displays bike large view.........................................

function newWindow3(pic){

leftPos = 0
  if (screen) {
    leftPos = screen.width-600

}
newsWin = window.open( pic, "photos", "height=365,width=390,left="+ leftPos +",top=50,scrollbars=yes");
newsWin.focus()
}


// Upcoming contest & pics Window.........................................

function contestWindow(page){

leftPos = 0
  if (screen) {
    leftPos = screen.width-750

}
newsWin = window.open( page,  "info", "height=275,width=475,left="+ leftPos +",top=50,scrollbars=yes");
newsWin.focus()
}


// displays wallpaper image and download info......................

function wallpaperDemo(pic){


leftPos = 0
  if (screen) {
     leftPos = screen.width-500
}
  
 
windowOutput = window.open("","output", "height=375,width=450,left="+ leftPos +",top=0,scrollbars=yes")
windowOutput.document.write("<HTML><HEAD><TITLE>Wallpaper Download</TITLE></HEAD><BODY bgcolor=#FFFFFF>")
windowOutput.document.write("<table><tr><td><Font face='arial' size='+2' color='#990000'><b>Wallpaper Sample</b></font></td><td align='center'><a href='javascript:close()'><font face='arial' size='2'>Close Window</a></font></td></tr>")
windowOutput.document.write("<tr><td colspan='2'><img src='images/wallpaperdemo/" + pic + ".jpg'></td></tr>") 
windowOutput.document.write("</table></BODY></HTML>")
windowOutput.focus()


 }


// displays wallpaper image and download info......................

function wallpaperWindow(pic){

leftPos = 0
  if (screen) {
     leftPos = screen.width-500
}
windowOutput = window.open("","output", "height=375,width=450,left="+ leftPos +",top=0,scrollbars=yes")
windowOutput.document.write("<HTML><HEAD><TITLE>Wallpaper Download</TITLE></HEAD><BODY bgcolor=#FFFFFF>")
windowOutput.document.write("<h2>Wallpaper Download</h2>")
windowOutput.document.write("<table><tr><td><img src='images/wallpaper/" + pic + ".jpg'></td></tr><tr><td>") 
windowOutput.document.write("<a href='javascript:close()'><font face='arial' size='2'>Close Window</a></font></td></tr></table>")
windowOutput.document.write("</BODY></HTML>")


}


// dropdown list redirects window...............................


function selectPage(newLoc) {
page=newLoc.options[newLoc.selectedIndex].value

if (page!="")  {

this.location = page

}

  }



// dropdown list opens in new window...............................


function selectNews(newLoc) {
page=newLoc.options[newLoc.selectedIndex].value

if (page!="")  {

newWindow=window.open( page )

}

  }
  
  
// email this page.......................................................


function emailthis(loc){
location.href="mailto:" + "?body=" + loc;

  }



// history window function................................................

pageArray = new Array("","tour1.htm","tour2.htm","tour3.htm")

function setPage(thispage){
parent.content.document.location.href= pageArray[thispage]

    }
    
    
// set cookie for vote.....................................................


function checkVote(v) {

expireDate = new Date()
expireDate.setDate(expireDate.getDate()+1);

   
   voteCt = ""
     
if (document.cookie != ""){
voteCt = document.cookie.split("; ")
}
   for (i=0; i<voteCt.length; i++)  {
 
     if (v == voteCt[i].split("=")[1]) {

          alert('You have already voted. Please try again next week.')
      
                 return false
           
           }
      }
      
   
//document.cookie = "voted="+ v +"; expires="+ expireDate.toGMTString();
  
  

  }
  
  
  
  
  function sendVote(v){
  
  expireDate = new Date()
  expireDate.setDate(expireDate.getDate()+30);

  voteCt = ""
  writecookie = "1"   
  results = "-1"
         
    for (i=0; i<document.poll.a.length; i++) {
    
     if (document.poll.a[i].checked) {     
     results = document.poll.a[i].value
   
     
     }
        }
        
  if (results == -1){
  alert("Please make a selection");
  return false
  }
  
      
//remove all the way to document.cookie if doesn't work

   
if (document.cookie != ""){
voteCt = document.cookie.split("; ")
}
   for (i=0; i<voteCt.length; i++)  {
 
     if (v == voteCt[i].split("=")[1]) {

          alert('You have already voted. Please try again next week.')
      
                 return false
           
           }
      }
      
   
document.cookie = "voted="+ v +"; expires="+ expireDate.toGMTString();

 

      voteWin = window.open(location.href="http://www.carlinvilleonline.net/vote/vote.pl?" + "a=" +results+ "&name=first",  "vote", "height=350,width=500,scrollbars=no");
  voteWin.focus()
        
            }
            
 // end cookie and new window
 


// vote results window..............................................................
 
 function voteResults(page){

    resultsWin = window.open(page, "results", "height=350,width=500,scrollbars=no");
    resultsWin.focus()

     }
     
     
 
 
         
//-->






