 home_on = new Image;
 home_on.src = "/images/home_over.gif";
 home_off = new Image;
 home_off.src = "/images/home.gif";

 videos_on = new Image;
 videos_on.src = "/images/videos_over.gif";
 videos_off = new Image;
 videos_off.src = "/images/videos.gif";
 
 pics_on = new Image;
 pics_on.src = "/images/pics_over.gif";
 pics_off = new Image;
 pics_off.src = "/images/pics.gif";
 
 stories_on = new Image;
 stories_on.src = "/images/stories_over.gif";
 stories_off = new Image;
 stories_off.src = "/images/stories.gif";
 
 txts_on = new Image;
 txts_on.src = "/images/txts_over.gif";
 txts_off = new Image;
 txts_off.src = "/images/txts.gif";
 
 games_on = new Image;
 games_on.src = "/images/games_over.gif";
 games_off = new Image;
 games_off.src = "/images/games.gif";


 px_blue = new Image;
 px_blue.src = "/images/px_blue.gif";

 px_red = new Image;
 px_red.src = "/images/px_red.gif";




 bloaded = true;

function bu1(imgName){
  if (bloaded){
    var theOBJ = (document.getElementById) ? document.getElementById(imgName) : eval("document.all['" + imgName + "']");
    theOBJ.src= eval(imgName + "_on.src");
  }
}

function bu0(imgName){
  if (bloaded){
    var theOBJ = (document.getElementById) ? document.getElementById(imgName) : eval("document.all['" + imgName + "']");
    theOBJ.src= eval(imgName + "_off.src");
  }
}



function rateon(i){
  var theOBJ = (document.getElementById) ? document.getElementById('rate'+i) : eval("document.all['rate"+i+"']");
  theOBJ.src= px_red.src;
}

function rateoff(i){
  var theOBJ = (document.getElementById) ? document.getElementById('rate'+i) : eval("document.all['rate"+i+"']");
  theOBJ.src= px_blue.src;
}


function newWin(url, name, w, h) {
  l = (screen.availWidth - w) / 2;
  t = (screen.availHeight - h) / 2;

  features = "width="+w+",height="+h+",left="+l+",top="+t;
  features += ",screenX="+l+",screenY="+t;
  features += ",scrollbars=0,resizable=0,location=0";
  features += ",menubar=0,toolbar=0,status=0";

  window.open(url, name, features);
} 




function head1(i){
 var theOBJ = (document.getElementById) ? document.getElementById('tbh'+i) : eval("document.all['tbh"+i+"']");
 theOBJ.className='header1';

}

function head0(i){
 var theOBJ = (document.getElementById) ? document.getElementById('tbh'+i) : eval("document.all['tbh"+i+"']");
 theOBJ.className='header0';
}




if (document.layers){
document.captureEvents(Event.MOUSEDOWN);
document.onmousedown=voidme;
}
else if (document.all&&!document.getElementById){
document.onmousedown=voidme;
}

function voidme(){
return false;
}

document.oncontextmenu=voidme;



function quick(value){
document.getElementById('movie').innerHTML='<object classid="clsid:02BF25D5-8C17-4B23-BC80-D3488ABDDC6B" '
+'width="300" height="240" codebase="http://www.apple.com/qtactivex/qtplugin.cab">'
+'<param name="src" value="'+value+'">'
+'<param name="autoplay" value="true">'
+'<param name="controller" value="true">'
+'<param name="loop" value="false">'
+'<EMBED src="'+value+'" width="300" height="240" autoplay="true" '
+'controller="true" loop="false" pluginspage="http://www.apple.com/quicktime/download/"></embed></object>';
}

function wmp(value){
document.getElementById('movie').innerHTML='<OBJECT id="mediaPlayer" width="300" height="240" '
+'classid="CLSID:22d6f312-b0f6-11d0-94ab-0080c74c7e95" '
+'codebase="http://activex.microsoft.com/activex/controls/mplayer/en/nsmp2inf.cab#Version=5,1,52,701" '
+'standby="Loading Microsoft Windows Media Player components..." type="application/x-oleobject"> '
+'<param name="fileName" value="'+value+'">'
+'<param name="ShowDisplay" value="0">'
+'<param name="ShowStatusBar" value="1">'
+'<param name="animationatStart" value="true">'
+'<param name="transparentatStart" value="false">'
+'<param name="autoStart" value="true">'
+'<param name="showControls" value="true">'
+'<param name="loop" value="false">'
+'<embed type="application/x-mplayer2" '
+'pluginspage="http://microsoft.com/windows/mediaplayer/en/download/" '
+'id="mediaPlayer2" name="mediaPlayer" displaysize="4" autosize="-1" '
+'bgcolor="darkblue" showcontrols="true" showtracker="-1" '
+'showdisplay="0" showstatusbar="1" videoborder3d="-1" width="300" height="240" '
+'src="'+value+'" autostart="true" designtimesp="5311" loop="false"></embed></object>';
}

function real(value){
document.getElementById('movie').innerHTML='<OBJECT ID=RVOCX CLASSID="clsid:CFCDAA03-8BE4-11cf-B84B-0020AFBBCCFA" WIDTH=320 HEIGHT=240>'
+'<PARAM NAME="SRC" VALUE="'+value+'">'
+'<PARAM NAME="CONTROLS" VALUE="ImageWindow,ControlPanel">'
+'<PARAM NAME="CONSOLE" VALUE="one">'
+'<PARAM NAME="AUTOSTART" VALUE="-1">'
+'<param name="_ExtentX" value="106">'
+'<param name="_ExtentY" value="53">'
+'<param name="SHUFFLE" value="0">'
+'<param name="PREFETCH" value="0">'
+'<param name="NOLABELS" value="0">'
+'<param name="LOOP" value="0">'
+'<param name="NUMLOOP" value="0">'
+'<param name="CENTER" value="0">'
+'<param name="MAINTAINASPECT" value="0">'
+'<param name="BACKGROUNDCOLOR" value="#000000">'
+'<EMBED SRC="'+value+'" WIDTH=320 HEIGHT=240 NOJAVA=true CONTROLS="ImageWindow,ControlPanel" CONSOLE=one AUTOSTART=true></OBJECT>'
}





function ratethis(ContType,ContID,Rating){

  switch(ContType){
    case 'videos': document.location.href = '/funnyvideos_rate.asp?vid='+ContID+'&r='+Rating; break
    case 'pictures': document.location.href = '/funnypics_rate.asp?p='+ContID+'&r='+Rating; break
    case 'stories': document.location.href = '/funnystories_rate.asp?s='+ContID+'&r='+Rating; break
  }
}


