curc = 0;
function worldover(id){
	if(curc>0){
		document.getElementById('c'+curc).style.display = 'none';
		document.getElementById('l'+curc).className = '';
	}
	if(id>0){
		document.getElementById('c'+id).style.display = 'block';
		document.getElementById('l'+id).className = 'on';
	}
	curc = id;
}

function nws(site_id,dir){
	p+= dir;
	var xmlhttp = xmlhttp_instance();
	xmlhttp.open("GET", "newslist.php?site_id="+site_id+"&p="+p);
	xmlhttp.onreadystatechange=function() {
		if (xmlhttp.readyState==4){
			eval(xmlhttp.responseText);
		}
	}
	xmlhttp.send(null);
	return false;
}

function xmlhttp_instance(){
	var xmlhttp=false;
	/*@cc_on @*/
	/*@if (@_jscript_version >= 5)
	// JScript gives us Conditional compilation, we can cope with old IE versions.
	// and security blocked creation of the objects.
	 try {
	  xmlhttp = new ActiveXObject("Msxml2.XMLHTTP");
	 } catch (e) {
	  try {
	   xmlhttp = new ActiveXObject("Microsoft.XMLHTTP");
	  } catch (E) {
	   xmlhttp = false;
	  }
	 }
	@end @*/
	if (!xmlhttp && typeof XMLHttpRequest!='undefined') {
	  xmlhttp = new XMLHttpRequest();
	}
	//xmlhttp.setRequestHeader('charset', 'ISO-8859-1');
	return xmlhttp;
}
