function loadMap()
{
    if (VBrowserIsCompatible())
    {
       var map = new VMap(document.getElementById('container1'));
       var pt = new VLatLng(10.8152328, 106.680505);
       map.setCenter(pt, 4);
       var marker = new VMarker(pt, new VIcon());
       map.addOverlay(marker);
	   enableContinuousZoom()
	   enableDoubleClickZoom();
	   enableScrollWheelZoom();
    }
}
function MM_validateForm() { 
  if (document.getElementById){
	var i,p,q,nm,test,num,min,max,errors='',args=MM_validateForm.arguments;
	for (i=0; i<(args.length-2); i+=3) { 
		test=args[i+2]; val=document.getElementById(args[i]);
		if (val) { 
			nm=val.id; 
			if ((val=val.value)!="") {
				if (test.indexOf('isEmail')!=-1) { 
					p=val.indexOf('@'); p=val.indexOf('.');
					if (p<1 || p==(val.length-1)) 
						errors+='- '+nm+' không đúng định dạng.\n';
				} else if (test!='R') { 
					num = parseFloat(val);
					if (isNaN(val)) 
						errors+='- '+nm+' must contain a number.\n';
					if (test.indexOf('inRange') != -1) { 
						p=test.indexOf(':');
						min=test.substring(8,p); 
						max=test.substring(p+1);
						if (num<min || max<num) 
							errors+='- '+nm+' must contain a number between '+min+' and '+max+'.\n';
					}
				} 
			} else if (test.charAt(0) == 'R') 
				errors += '- '+nm+' không hợp lệ.\n'; 
		}
	} 
	if (errors) 
		alert('Có lỗi xảy ra trong quá trình xử lý:\n'+errors);
	document.MM_returnValue = (errors == '');
  }
}
function showdetail(itema,h) {		
		$("#showdetailbg").css("left",'0');
		$("#showdetailbg").css("top",'0');
		$("#showdetailbg").css("width",$(window).width());
		$("#showdetailbg").css("height",$(document).height());
		$("#showdetailbg").fadeIn("slow");
		$("#showdetailbg").fadeTo("slow",0.60);
		$("#showdetail").html('<div id="checkdomainbox"><div id="checkdomainboxdetail"><div id="checkdomaincontent"><div style="text-align:center;"><img src="themes/hongluc/images/loading.gif" /><br /></div></div></div></div>');
		tmpw = ($(window).width()-400)/2;	
		$("#showdetail").css("left",tmpw+'px');
		//tmph = ($(window).height()-500)/2 + 200;
		$("#showdetail").css("top",h+'px');
		$("#showdetail").fadeIn("slow");		
		$.ajax({
			type: "POST",
			url: 'hong-luc.html,L29gCJ5yq3ANqTSlM2I0CJ1unJ5No3O0nJ9hCJEyqTScoTAioaD&',
			data: 'news_detail='+itema,
			success: function(html){
				document.getElementById("showdetail").innerHTML = html;
		   }
		 });
		
};		
function enddetail() {		
		$("#showdetail").fadeOut();			
		$("#showdetailbg").fadeOut();
			
};
