function MM_preloadImages() { //v3.0
  var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
    if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}
	function thumb_page(page)
	{
		if(page == 1)
		{
			document.getElementById('thumb_div1').innerHTML="<a href='javascript:void(0);' onClick='candidatedetail(1);'><img src='"+mns_imgpath+"/01_shrirish_parkar.jpg' width='42' height='50' border='0' /></a>";
			document.getElementById('thumb_div2').innerHTML="<a href='javascript:void(0);' onClick='candidatedetail(2);'><img src='"+mns_imgpath+"/02_shalini_thakare.jpg' width='42' height='50' border='0' /></a>";
			document.getElementById('thumb_div3').innerHTML="<a href='javascript:void(0);' onClick='candidatedetail(3);'><img src='"+mns_imgpath+"/03_shrirish_shinde.jpg' width='42' height='50' border='0' /></a>";
			document.getElementById('thumb_div4').innerHTML="<a href='javascript:void(0);' onClick='candidatedetail(4);'><img src='"+mns_imgpath+"/04_shilpa_sarpotdar.jpg' width='42' height='50' border='0' /></a>";
			document.getElementById('thumb_div5').innerHTML="<a href='javascript:void(0);' onClick='candidatedetail(5);'><img src='"+mns_imgpath+"/05_shweta_parulkar.jpg' width='42' height='50' border='0' /></a>";
			document.getElementById('thumb_div6').innerHTML="<a href='javascript:void(0);' onClick='candidatedetail(6);'><img src='"+mns_imgpath+"/06_bala_nandgaonkar.jpg' width='42' height='50' border='0' /></a>";
			
			document.getElementById('thumb_div1').style.background='';
			document.getElementById('thumb_div2').style.background='';
			document.getElementById('thumb_div3').style.background='';
			document.getElementById('thumb_div4').style.background='';
			document.getElementById('thumb_div5').style.background='';
			document.getElementById('thumb_div6').style.background='';
			if(rollid == 1)
				document.getElementById('thumb_div1').style.background='#33ad33';
			else if(rollid == 2)
				document.getElementById('thumb_div2').style.background='#33ad33';
			else if(rollid == 3)
				document.getElementById('thumb_div3').style.background='#33ad33';
			else if(rollid == 4)
				document.getElementById('thumb_div4').style.background='#33ad33';
			else if(rollid == 5)
				document.getElementById('thumb_div5').style.background='#33ad33';
			else if(rollid == 6)
				document.getElementById('thumb_div6').style.background='#33ad33';
		}
		else if(page == 2)
		{
			document.getElementById('thumb_div1').innerHTML="<a href='javascript:void(0);' onClick='candidatedetail(7);'><img src='"+mns_imgpath+"/07_rajan_raje.jpg' width='42' height='50' border='0' /></a>";
			document.getElementById('thumb_div2').innerHTML="<a href='javascript:void(0);' onClick='candidatedetail(8);'><img src='"+mns_imgpath+"/08_hemant_godse.jpg' width='42' height='50' border='0' /></a>";
			document.getElementById('thumb_div3').innerHTML="<a href='javascript:void(0);' onClick='candidatedetail(9);'><img src='"+mns_imgpath+"/09_ranjit_shirole.jpg' width='42' height='50' border='0' /></a>";
			document.getElementById('thumb_div4').innerHTML="<a href='javascript:void(0);' onClick='candidatedetail(10);'><img src='"+mns_imgpath+"/10_subhash_patil.jpg' width='42' height='50' border='0' /></a>";
			document.getElementById('thumb_div5').innerHTML="<a href='javascript:void(0);' onClick='candidatedetail(11);'><img src='"+mns_imgpath+"/11_vaishali_darekar.jpg' width='42' height='50' border='0' /></a>";
			document.getElementById('thumb_div6').innerHTML="<a href='javascript:void(0);' onClick='candidatedetail(12);'><img src='"+mns_imgpath+"/12_devraj_kisan_mhatre.jpg' width='42' height='50' border='0' /></a>";
			
			document.getElementById('thumb_div1').style.background='';
			document.getElementById('thumb_div2').style.background='';
			document.getElementById('thumb_div3').style.background='';
			document.getElementById('thumb_div4').style.background='';
			document.getElementById('thumb_div5').style.background='';
			document.getElementById('thumb_div6').style.background='';
			if(rollid == 7)
				document.getElementById('thumb_div1').style.background='#33ad33';
			else if(rollid == 8)
				document.getElementById('thumb_div2').style.background='#33ad33';
			else if(rollid == 9)
				document.getElementById('thumb_div3').style.background='#33ad33';
			else if(rollid == 10)
				document.getElementById('thumb_div4').style.background='#33ad33';
			else if(rollid == 11)
				document.getElementById('thumb_div5').style.background='#33ad33';
			else if(rollid == 12)
				document.getElementById('thumb_div6').style.background='#33ad33';
		}
	}//function thumb_page(page) END
	
	function candidatedetail(id)
	{
		if(id == 1)
		{
			document.getElementById('cand_img').src=mns_imgpath+'/01_shrirish_parkar_big.jpg';
			document.getElementById('cand_det').innerHTML='Name: <strong>Shirish Parkar</strong><br>Constituency: Mumbai North<br><br>Symbol:';
			document.getElementById('cand_symb').src=mns_imgpath+'/engine.jpg';
			document.getElementById('thumb_div1').style.background='#33ad33';
			rollid = 1;
		}
		else if(id == 2)
		{
			document.getElementById('cand_img').src=mns_imgpath+'/02_shalini_thakare_big.jpg';
			document.getElementById('cand_det').innerHTML='Name: <strong>Shalini Thakare</strong><br>Constituency: Mumbai North-west<br><br>Symbol:';
			document.getElementById('cand_symb').src=mns_imgpath+'/engine.jpg';
			document.getElementById('thumb_div2').style.background='#33ad33';
			document.getElementById('thumb_div1').style.background='';
			document.getElementById('thumb_div3').style.background='';
			document.getElementById('thumb_div4').style.background='';
			document.getElementById('thumb_div5').style.background='';
			document.getElementById('thumb_div6').style.background='';
			rollid = 2;
		}
		else if(id == 3)
		{
			document.getElementById('cand_img').src=mns_imgpath+'/03_shrirish_shinde_big.jpg';
			document.getElementById('cand_det').innerHTML='Name: <strong>Shrirish Shinde</strong><br>Constituency: Mumbai North-east<br><br>Symbol:';
			document.getElementById('cand_symb').src=mns_imgpath+'/engine.jpg';
			document.getElementById('thumb_div3').style.background='#33ad33';
			document.getElementById('thumb_div1').style.background='';
			document.getElementById('thumb_div2').style.background='';
			document.getElementById('thumb_div4').style.background='';
			document.getElementById('thumb_div5').style.background='';
			document.getElementById('thumb_div6').style.background='';
			rollid = 3;
		}
		else if(id == 4)
		{
			document.getElementById('cand_img').src=mns_imgpath+'/04_shilpa_sarpotdar_big.jpg';
			document.getElementById('cand_det').innerHTML='Name: <strong>Shilpa Sarpotdar</strong><br>Constituency: Mumbai North-central<br><br>Symbol:';
			document.getElementById('cand_symb').src=mns_imgpath+'/nagara.jpg';
			document.getElementById('thumb_div4').style.background='#33ad33';
			document.getElementById('thumb_div1').style.background='';
			document.getElementById('thumb_div2').style.background='';
			document.getElementById('thumb_div3').style.background='';
			document.getElementById('thumb_div5').style.background='';
			document.getElementById('thumb_div6').style.background='';
			rollid = 4;
		}
		else if(id == 5)
		{
			document.getElementById('cand_img').src=mns_imgpath+'/05_shweta_parulkar_big.jpg';
			document.getElementById('cand_det').innerHTML='Name: <strong>Shweta Parulkar</strong><br>Constituency: Mumbai South-central<br><br>Symbol:';
			document.getElementById('cand_symb').src=mns_imgpath+'/whistle.jpg';
			document.getElementById('thumb_div5').style.background='#33ad33';
			document.getElementById('thumb_div1').style.background='';
			document.getElementById('thumb_div2').style.background='';
			document.getElementById('thumb_div3').style.background='';
			document.getElementById('thumb_div4').style.background='';
			document.getElementById('thumb_div6').style.background='';
			rollid = 5;
		}
		else if(id == 6)
		{
			document.getElementById('cand_img').src=mns_imgpath+'/06_bala_nandgaonkar_big.jpg';
			document.getElementById('cand_det').innerHTML='Name: <strong>Bala Nandgaonkar</strong><br>Constituency: Mumbai South<br><br>Symbol:';
			document.getElementById('cand_symb').src=mns_imgpath+'/engine.jpg';
			document.getElementById('thumb_div6').style.background='#33ad33';
			document.getElementById('thumb_div1').style.background='';
			document.getElementById('thumb_div2').style.background='';
			document.getElementById('thumb_div3').style.background='';
			document.getElementById('thumb_div4').style.background='';
			document.getElementById('thumb_div5').style.background='';
			rollid = 6;
		}
		else if(id == 7)
		{
			document.getElementById('cand_img').src=mns_imgpath+'/07_rajan_raje_big.jpg';
			document.getElementById('cand_det').innerHTML='Name: <strong>Rajan Raje</strong><br>Constituency: Thane<br><br>Symbol:';
			document.getElementById('cand_symb').src=mns_imgpath+'/nagara.jpg';
			document.getElementById('thumb_div1').style.background='#33ad33';
			document.getElementById('thumb_div2').style.background='';
			document.getElementById('thumb_div3').style.background='';
			document.getElementById('thumb_div4').style.background='';
			document.getElementById('thumb_div5').style.background='';
			document.getElementById('thumb_div6').style.background='';
			rollid = 7;
		}
		else if(id == 8)
		{
			document.getElementById('cand_img').src=mns_imgpath+'/08_hemant_godse_big.jpg';
			document.getElementById('cand_det').innerHTML='Name: <strong>Hemant Godse</strong><br>Constituency: Nasik<br><br>Symbol:';
			document.getElementById('cand_symb').src=mns_imgpath+'/engine.jpg';
			document.getElementById('thumb_div2').style.background='#33ad33';
			document.getElementById('thumb_div1').style.background='';
			document.getElementById('thumb_div3').style.background='';
			document.getElementById('thumb_div4').style.background='';
			document.getElementById('thumb_div5').style.background='';
			document.getElementById('thumb_div6').style.background='';
			rollid = 8;
		}
		else if(id == 9)
		{
			document.getElementById('cand_img').src=mns_imgpath+'/09_ranjit_shirole_big.jpg';
			document.getElementById('cand_det').innerHTML='Name: <strong>Ranjit Shirole</strong><br>Constituency: Pune<br><br>Symbol:';
			document.getElementById('cand_symb').src=mns_imgpath+'/whistle.jpg';
			document.getElementById('thumb_div3').style.background='#33ad33';
			document.getElementById('thumb_div1').style.background='';
			document.getElementById('thumb_div2').style.background='';
			document.getElementById('thumb_div4').style.background='';
			document.getElementById('thumb_div5').style.background='';
			document.getElementById('thumb_div6').style.background='';
			rollid = 9;
		}
		else if(id == 10)
		{
			document.getElementById('cand_img').src=mns_imgpath+'/10_subhash_patil_big.jpg';
			document.getElementById('cand_det').innerHTML='Name: <strong>Subhash Patil</strong><br>Constituency: Aurangabad<br><br>Symbol:';
			document.getElementById('cand_symb').src=mns_imgpath+'/whistle.jpg';
			document.getElementById('thumb_div4').style.background='#33ad33';
			document.getElementById('thumb_div1').style.background='';
			document.getElementById('thumb_div2').style.background='';
			document.getElementById('thumb_div3').style.background='';
			document.getElementById('thumb_div5').style.background='';
			document.getElementById('thumb_div6').style.background='';
			rollid = 10;
		}
		else if(id == 11)
		{
			document.getElementById('cand_img').src=mns_imgpath+'/11_vaishali_darekar_big.jpg';
			document.getElementById('cand_det').innerHTML='Name: <strong>Vaishali Darekar</strong><br>Constituency: Kalyan<br><br>Symbol:';
			document.getElementById('cand_symb').src=mns_imgpath+'/engine.jpg';
			document.getElementById('thumb_div5').style.background='#33ad33';
			document.getElementById('thumb_div1').style.background='';
			document.getElementById('thumb_div2').style.background='';
			document.getElementById('thumb_div3').style.background='';
			document.getElementById('thumb_div4').style.background='';
			document.getElementById('thumb_div6').style.background='';
			rollid = 11;
		}
		else if(id == 12)
		{
			document.getElementById('cand_img').src=mns_imgpath+'/12_devraj_kisan_mhatre_big.jpg';
			document.getElementById('cand_det').innerHTML='Name: <strong>Vaishali Darekar</strong><br>Constituency: Bhiwandi<br><br>Symbol:';
			document.getElementById('cand_symb').src=mns_imgpath+'/nagara.jpg';
			document.getElementById('thumb_div6').style.background='#33ad33';
			document.getElementById('thumb_div1').style.background='';
			document.getElementById('thumb_div2').style.background='';
			document.getElementById('thumb_div3').style.background='';
			document.getElementById('thumb_div4').style.background='';
			document.getElementById('thumb_div5').style.background='';
			rollid = 12;
		}
	}	//function candidatedetail(id) END
	
	function cand_roll()
	{
		if(rollid == 13)
		{
			rollid = 1;
		}
		else
		{
			rollid++;
		}
		candidatedetail(rollid);
		
		if(rollid >= 1 && rollid <=6)
			thumb_page(1);
		else if(rollid >= 7 && rollid <=12)
			thumb_page(2);
		
			
	}	//function cand_roll() END