var xmlhttp2;

function loadScroll(){
	url = "news_view2.php?c="+Math.random();
	
	xmlhttp2 = null;
	var b = 1;
	// code for Mozilla, etc.
	if (window.XMLHttpRequest)
	  {
	  xmlhttp2 = new XMLHttpRequest();	  
	  }					
	else if (window.ActiveXObject) 
	  { // code for IE
	  xmlhttp2=new ActiveXObject("Microsoft.xmlhttp");	  
	  }
	if (xmlhttp2 != null)
	  {	  
	  xmlhttp2.onreadystatechange = state_Change;
	  xmlhttp2.open("GET",url,true);
	  xmlhttp2.send(null);
	  }
	else
	  {
	  alert("Your browser does not support xmlhttp.")
	  }
}

function state_Change(){
	
	var content = document.getElementById('scroll');
	var isIE = false;
	var ua = navigator.userAgent;
	var s = "MSIE";	
		
	// Checking for IE Version
	if (ua.indexOf(s)>0) {
    	isIE = true;		
	}	
	// if xmlhttp2 shows "loaded"
	if (xmlhttp2.readyState==4){
		// if "OK"
		if (xmlhttp2.status==200){
			content.style.display = 'block';				
			content.innerHTML=xmlhttp2.responseText;
		}
		else{
			alert("Problem retrieving Data:" + xmlhttp2.statusText);
			content.style.display = 'none';
		}		
	}
	else{		
		content.style.display = 'block';
		content.innerHTML='<center><br><img src="images/loading.gif"><br><br></center>';
	}
	
}

function feature_close(){
	document.getElementById('scroll').style.display = 'none';	
}
