

var video1=new Array("<object width=\"425\" height=\"344\"><param name=\"movie\" value=\"http://www.youtube.com/v/JnEF55Ehu9M&hl=en&fs=1&\"></param><param name=\"allowFullScreen\" value=\"true\"></param><param name=\"allowscriptaccess\" value=\"always\"></param><embed src=\"http://www.youtube.com/v/JnEF55Ehu9M&hl=en&fs=1&\" type=\"application/x-shockwave-flash\" allowscriptaccess=\"always\" allowfullscreen=\"true\" width=\"425\" height=\"344\"></embed></object>","China Summary","http://www.in.gov/gov/files/video/China_Summary.wmv");

var video2=new Array("<object width=\"425\" height=\"344\"><param name=\"movie\" value=\"http://www.youtube.com/v/2mRMeJ4AETg&hl=en&fs=1&\"></param><param name=\"allowFullScreen\" value=\"true\"></param><param name=\"allowscriptaccess\" value=\"always\"></param><embed src=\"http://www.youtube.com/v/2mRMeJ4AETg&hl=en&fs=1&\" type=\"application/x-shockwave-flash\" allowscriptaccess=\"always\" allowfullscreen=\"true\" width=\"425\" height=\"344\"></embed></object>","Hangzhou Cummins Bus Launch","http://www.in.gov/gov/files/video/090909_Cummins.wmv");

var video3=new Array("<object width=\"425\" height=\"344\"><param name=\"movie\" value=\"http://www.youtube.com/v/hSXjzJbIJn0&hl=en&fs=1&\"></param><param name=\"allowFullScreen\" value=\"true\"></param><param name=\"allowscriptaccess\" value=\"always\"></param><embed src=\"http://www.youtube.com/v/hSXjzJbIJn0&hl=en&fs=1&\" type=\"application/x-shockwave-flash\" allowscriptaccess=\"always\" allowfullscreen=\"true\" width=\"425\" height=\"344\"></embed></object>","Shanghai Greentech Conference","http://www.in.gov/gov/files/video/090809_Greentech.wmv");

var video4=new Array("<object width=\"425\" height=\"344\"><param name=\"movie\" value=\"http://www.youtube.com/v/rmjdSUAOdyo&hl=en&fs=1&border=1\"></param><param name=\"allowFullScreen\" value=\"true\"></param><param name=\"allowscriptaccess\" value=\"always\"></param><embed src=\"http://www.youtube.com/v/rmjdSUAOdyo&hl=en&fs=1&border=1\" type=\"application/x-shockwave-flash\" allowscriptaccess=\"always\" allowfullscreen=\"true\" width=\"425\" height=\"344\"></embed></object>","Gov. Daniels: Fighting the Recession to Win","http://www.in.gov/gov/files/video/081909_SB.wmv");

var video5=new Array("<object width=\"425\" height=\"344\"><param name=\"movie\" value=\"http://www.youtube.com/v/-0gpsrdnbH8&hl=en&fs=1&\"></param><param name=\"allowFullScreen\" value=\"true\"></param><param name=\"allowscriptaccess\" value=\"always\"></param><embed src=\"http://www.youtube.com/v/-0gpsrdnbH8&hl=en&fs=1&\" type=\"application/x-shockwave-flash\" allowscriptaccess=\"always\" allowfullscreen=\"true\" width=\"425\" height=\"344\"></embed></object>","2009 Ride with the GOV","http://www.in.gov/gov/files/video/2009_ABATE_Ride.wmv");





function displayvideo(video,state){
var currentvideo = document.getElementById('currentvideo');
var yt = document.getElementById('yt');
var wmv = document.getElementById('wmv');
var fixEmbeddedVideo = function(embedCode) {
	if(embedCode && embedCode.toLowerCase().indexOf('classid') == -1) {
		var objPos = embedCode.toLowerCase().indexOf('object ') + 'object '.length;
		return embedCode.substr(0, objPos) + 'classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" ' + embedCode.substr(objPos);
	} else {
		return embedCode;
	}
}

function ytactive(){
yt.setAttribute('className','active');
yt.setAttribute('class','active');
}

function ytinactive(){
yt.setAttribute('className','inactive');
yt.setAttribute('class','inactive');
}

function wmvactive(){
wmv.setAttribute('className','active');
wmv.setAttribute('class','active');
}

function wmvinactive(){
wmv.setAttribute('className','inactive');
wmv.setAttribute('class','inactive');
}

var x = 'videos' + video;
for(i=1;i<6;i++){
var y = 'videos' + i;
	if (i==video){
	document.getElementById(x).setAttribute('className','vactive');
	document.getElementById(x).setAttribute('class','vactive');	
	}
	else if(i!=video)
	{
	document.getElementById(y).setAttribute('className','vinactive');	
	document.getElementById(y).setAttribute('class','vinactive');	
	}
}

if (video=="1"){

	if (state=='yt'){
	currentvideo.innerHTML=fixEmbeddedVideo(video1[0]);
	yt.firstChild.setAttribute('href','javascript:displayvideo(\'1\',\'yt\'\)');
	ytactive();
	wmv.firstChild.setAttribute('href','javascript:displayvideo(\'1\',\'wmv\'\)');
	wmvinactive();
		}
	else{		
	currentvideo.innerHTML='<div id\=\"emptydiv\"><h4>' + video1[1] + '</h4></div>';
	yt.firstChild.setAttribute('href','javascript:displayvideo(\'1\',\'yt\'\)');
	ytinactive();
	wmv.firstChild.setAttribute('href','javascript:displayvideo(\'1\',\'wmv\'\)');
	wmvactive();
	window.location.href=video1[2];
		}
		
	}
	

	else if (video=="2"){
	
		if (state=='yt'){
	currentvideo.innerHTML=fixEmbeddedVideo(video2[0]);
	yt.firstChild.setAttribute('href','javascript:displayvideo(\'2\',\'yt\'\)');
	ytactive();
	wmv.firstChild.setAttribute('href','javascript:displayvideo(\'2\',\'wmv\'\)');
	wmvinactive();
		}
		else {
	currentvideo.innerHTML='<div id\=\"emptydiv\"><h4>' + video2[1] + '</h4></div>';
	yt.firstChild.setAttribute('href','javascript:displayvideo(\'2\',\'yt\'\)');
	ytinactive();
	wmv.firstChild.setAttribute('href','javascript:displayvideo(\'2\',\'wmv\'\)');
	wmvactive();
	window.location.href=video2[2];
		}
		
	}
	else if (video=="3"){
	
		if (state=='yt'){
	currentvideo.innerHTML=fixEmbeddedVideo(video3[0]);
	yt.firstChild.setAttribute('href','javascript:displayvideo(\'3\',\'yt\'\)');
	ytactive();
	wmv.firstChild.setAttribute('href','javascript:displayvideo(\'3\'\)');
	wmvinactive();
		}
		else {
	currentvideo.innerHTML='<div id\=\"emptydiv\"><h4>' + video3[1] + '</h4></div>';
	yt.firstChild.setAttribute('href','javascript:displayvideo(\'3\',\'yt\'\)');
	ytinactive();
	wmv.firstChild.setAttribute('href','javascript:displayvideo(\'3\',\'wmv\'\)');
	wmvactive();
	window.location.href=video3[2];
		}
		
	}
	else if (video=="4"){
	
		if (state=='yt'){
	currentvideo.innerHTML=fixEmbeddedVideo(video4[0]);
	yt.firstChild.setAttribute('href','javascript:displayvideo(\'4\',\'yt\'\)');
	ytactive();
	wmv.firstChild.setAttribute('href','javascript:displayvideo(\'4\'\)');
	wmv.firstChild.setAttribute('onclick','window.open=\"' + video4[2] + '\"' );
	wmvinactive();
		}
		else {
	currentvideo.innerHTML='<div id\=\"emptydiv\"><h4>' + video4[1] + '</h4></div>';
	yt.firstChild.setAttribute('href','javascript:displayvideo(\'4\',\'yt\'\)');
	ytinactive();
	wmv.firstChild.setAttribute('href','javascript:displayvideo(\'4\',\'wmv\'\)');
	wmvactive();
	window.location.href=video4[2];
		}
		
	}
	else if (video=="5"){
	
		if (state=='yt'){
	currentvideo.innerHTML=fixEmbeddedVideo(video5[0]);
	yt.firstChild.setAttribute('href','javascript:displayvideo(\'5\',\'yt\'\)');
	ytactive();
	wmv.firstChild.setAttribute('href','javascript:displayvideo(\'5\'\)');
	wmvinactive();
		}
		else {
	currentvideo.innerHTML='<div id\=\"emptydiv\"><h4>' + video5[1] + '</h4></div>';
	yt.firstChild.setAttribute('href','javascript:displayvideo(\'5\',\'yt\'\)');
	ytinactive();
	wmv.firstChild.setAttribute('href','javascript:displayvideo(\'5\',\'wmv\'\)');
	wmvactive();
	window.location.href=video5[2];
		}
	}



}

