function test(loc)
{
mktscanwin = window.open(loc,"test",'height=500,width=800,scrollbars,resizable=yes');
}
function p(loc)
{
mktscanwin = window.open(loc,"p",'height=460,width=750,scrollbars,resizable=yes');
}

function m(loc)
{
mktscanwin = window.open(loc,"m",'height=460,width=450,scrollbars,resizable=no');
}
function d(loc)
{
mktscanwin = window.open(loc,"d",'height=620,width=485,noscrollbars,resizable=no');
}
function c(loc)
{
mktscanwin = window.open(loc,"c",'height=600,width=700,scrollbars,resizable=no');
}

function e(loc)
{
mktscanwin = window.open(loc,"e",'height=400,width=600,scrollbars,resizable=yes');
}


function popup_lnk_open(x)
{
window.open(x,'','height=610,width=600,resizable=yes,scrollbars=yes,resizable=no');

}





    function MyReload() 
{ 
window.location.reload(); 
} 
     function windowopen(x)
{

if(document.all)
var xMax=screen.width,yMax=screen.height;
else
if(document.layers)
var xMax=window.outerWidth,yMax=window.outerHeight;
else
var xMax=640,yMax=480;
var xOffset=(xMax-450)/2,yOffset=(yMax-550)/2;
window.open(x,'','height=550,width=600,resizable=yes,scrollbars=yes,screenX='+xOffset+',screenY='+yOffset+',top='+yOffset+',left='+xOffset+'');

} 

    function windowopen_WithDynamiclength(x,l)
{

TheNewWin=window.open(x,'',l);
var h=window.screen.height;
var w=window.screen.width;
TheNewWin.moveTo(h/4,w/12);

}
    function fun_convocation(x)
        {
            
            if (x=='ban') 
                {
                   WinAdmitCard('ConvocationPic.aspx?cid=9&pno=1')
                    document.getElementById ('mum').style.display="none";   
                    document.getElementById ('che').style.display="none";   
                    document.getElementById ('ban').style.display="none";
                    //document.getElementById ('kol').style.display="none";
                     
                }
             else if (x=='kol') 
                {
                //alert("kol");
                                 
                    WinAdmitCard('ConvocationPic.aspx?cid=7&pno=1')
                    document.getElementById ('mum').style.display="none";   
                    document.getElementById ('che').style.display="none";   
                    document.getElementById ('ban').style.display="none";
                    //document.getElementById ('kol').style.display="none";
                } 
               else if (x=='mum') 
                {   
                    WinAdmitCard('ConvocationPic.aspx?cid=8&pno=1')
                
                    document.getElementById ('mum').style.display="none";   
                    document.getElementById ('che').style.display="none";   
                    document.getElementById ('ban').style.display="none";
                    //document.getElementById ('kol').style.display="none";
                }                                 
               else if (x=='che') 
                {
                    document.getElementById ('mum').style.display="none";   
                    document.getElementById ('che').style.display="block";   
                    document.getElementById ('ban').style.display="none";
                    //document.getElementById ('kol').style.display="none";
                }     
                else if (x=='del') 
                {
                    WinAdmitCard('ConvocationPic.aspx?cid=15&pno=1')
                    document.getElementById ('mum').style.display="none";   
                    document.getElementById ('che').style.display="none";   
                    document.getElementById ('ban').style.display="none";
                    //document.getElementById ('kol').style.display="none";
                }                               
            
            return false;
        }
        
        function WinAdmitCard(x)
	        {			    
				TheNewWin=window.open(x,'','height=550,width=600,resizable=yes,scrollbars=yes');
                TheNewWin.moveTo(200,50);
	        }		
    
   
    
    function windowpop(x)
    
        {
            TheNewWin=window.open(x,'','height=650,width=700,resizable=yes,scrollbars=yes');
            TheNewWin.moveTo(200,50);
            return true;
        }
     
    
function viewnews(PageNo)
  {

 showdropdown('Event.aspx?Path=4/30&PageNo=' + PageNo )
      
  }
  
  


var xmlHttp
var d

function showdropdown(str)
{ 
xmlHttp=GetXmlHttpObject1();
if (xmlHttp==null)
  {
  alert ("Your browser does not support AJAX!");
  return;
  } 
var url;
url=str;





xmlHttp.onreadystatechange=stateChanged1;

xmlHttp.open("GET",url,true);
xmlHttp.send(null);

}





function stateChanged1() 
{ 
if (xmlHttp.readyState==4 )
{
var hdTxt = new Array();
var hdTxt1 =  new Array();
var arrdoc = new Array();

//var str;
var strBD;
var head1;
var head2;
var headarr1;
var headarr2;

strBD = xmlHttp.responseText;



// replace path for showing image-----------------------------






// logic ends over here--------------------------------------



document.getElementById("Event").innerHTML = strBD;


}
}



//////////////////////////////////////////////////////////////////////////////////////
function GetXmlHttpObject1()
{
var xmlHttp=null;
try
  {

  xmlHttp=new XMLHttpRequest();
  }
catch (e)
  {
 
  try
    {
    xmlHttp=new ActiveXObject("Msxml2.XMLHTTP");
    }
  catch (e)
    {
    xmlHttp=new ActiveXObject("Microsoft.XMLHTTP");
    }
  }
return xmlHttp;
}

  

 function clickSearchButton(e, searchkeybutton){ 
		
		//var bt = document.getElementById(searchkeybutton); 
	
		if (searchkeybutton == 'Search_searchgoimg'){ 
		
				if(navigator.appName.indexOf("Netscape")>(-1)){ 
					if (e.keyCode == 13){ 
							
							searchKey();
					} 
				} 
				if (navigator.appName.indexOf("Microsoft Internet Explorer")>(-1)){ 
					if (event.keyCode == 13){ 
							
						return	searchKey();
					} 
				} 
		} 
} 
		
	
function searchKey() { 

	var searchkey=document.getElementById("txtSearchKey").value;
	
	if(searchkey != null) {
	
	
		if  (searchkey=='')	{
		
				alert('Please enter search key word' );
				//document.form1.txtSearchKey.focus();
				return false;
		}
		else
		
		
		{
	
		  //  document.form1.method="post"
		    //document.form1.action="Searchresult.aspx?path=0/53&condition="+searchkey.value;
		    //document.form1.submit;
			self.location.href="Searchresult.aspx?path=0/53&condition=" + searchkey;
			return false;	
			
		}
	}
}


function searchKey_img() { 
	var searchkey=document.getElementById("txtSearchKey").value;
	
	if(searchkey != null) {
	
	
		if  (searchkey=='' || searchkey=='Enter search term here')	{
				alert('Please enter search key word' );
				document.form1.txtSearchKey.focus();
				return false;	
		}
		else
		
		
		{
		   
			self.location.href="Searchresult.aspx?path=0/53&condition=" + searchkey;
			return true;	
			
		}
	}
}




function searchKeyRemoveText() { 
	var searchkey=document.form1.txtSearchKey; 
if(searchkey != null) {
                    if  (searchkey.value==''){
		                searchkey.value='';
		                }
	}
}




 
 







