//This controls the entrance message going from index.html to main.html
function confirm_enter(){
if (confirm("THE POLLS ARE READY!\n\nThey are located at the bottom of the next page, and they're painless.\n\nAs always... MORE CHANGES ARE COMING!!")){
return window.location.href="main.html";
}
}




//This displays the random quotes on the MAIN page
function random_imglink(){
var myimages=new Array()
//specify random images below. You can have as many as you wish
myimages[1]="/images/quote1.gif"
myimages[2]="/images/quote2.gif"
myimages[3]="/images/quote3.gif"
myimages[4]="/images/quote4.gif"
myimages[5]="/images/quote5.gif"
myimages[6]="/images/quote6.gif"

var ry=Math.floor(Math.random()*myimages.length)
if (ry==0)
ry=1
document.write('<img src="'+myimages[ry]+'" border=0>')
}






//Main page BACK button javascript popup alert

function confirm_ex(){
if (confirm("Do you REALLY want to go back? It's just a picture of my eye, folks... I mean really...\n\nOK=I love Justin's eye! Let me at it!\nCancel=Nooo! Anything but Justin's eye!")){
return window.location.href="/";
}
}



//Opens a link in a new window with specifications set in the link
function NewWindow(mypage, myname, w, h, scroll) {
var winl = (screen.width - w) / 2;
var wint = (screen.height - h) / 2;
winprops = 'height='+h+',width='+w+',top='+wint+',left='+winl+',scrollbars='+scroll+',resizable=no'
win = window.open(mypage, myname, winprops)
if (parseInt(navigator.appVersion) >= 4) { win.window.focus(); }
}


//Opens pictures in a new, automatically resized window
function PopupPic(sPicURL) { 
window.open("/popup.html?"+sPicURL, "", "resizable=0,scrollbars=0,scrollable=0,status=0,toolbar=0,menubar=0,location=0,LEFT=300,TOP=0,HEIGHT=200,WIDTH=200");
}


//Opens polls in a new, automatically resized window
function PopupPolls(URL) { 
window.open(URL, "", "resizable=0,scrollbars=0,scrollable=0,status=0,toolbar=0,menubar=0,location=0,LEFT=300,TOP=0,HEIGHT=450,WIDTH=180");
}
