<!--
function isSC(){
	var theURL = window.location.href;
	//alert("theURL="+theURL);
	var scURLs=new Array();
	var isSC = false;
	
	//scURLs[0]="http://sc.lcsd.gov.hk/gb/www.lcsd.gov.hk/";
	scURLs[0]="http://sc.lcsd.gov.hk/gb/";
	scURLs[1]="http://sc.lcsd.gov.hk/gb/sc_svr_2.lcsd.gov.hk/gb/cfserver.lcsd.gov.hk/";
	
	for (i=0; i<scURLs.length; i++) {
	//alert("scURLs[i]="+scURLs[i]);
		if (theURL.indexOf(scURLs[i])>=0) {
	  		isSC = true;
		}
	}
	//alert("isSC="+isSC);
	return isSC;
} 

function show_staticmap(gid, lang) {
	if(window.showPopupStaticMap) {
        //document.writeln('showPopupStaticMap exists<br />');
        //alert("Lands Department's GIHS system is work well!");
	    if (isSC()==true) {
	       showPopupStaticMap(gid, 'sc');
	    } else {
	       showPopupStaticMap(gid, lang);
	    }
    }
    else {
       //document.writeln('showPopupStaticMap does not exist<br />');
       //alert("Lands Department's GIHS system is down!");  //to alert message may cause approval check.
    }
	
}
function show_advancedmap(gid, lang) {

	if(window.showPopupStaticMap) {
        //document.writeln('showPopupStaticMap exists<br />');
        //alert("Lands Department's GIHS system is work well!");
	    if (isSC()==true) {
	       showPopupAdvancedMap(gid, 'sc');
	    } else {
	       showPopupAdvancedMap(gid, lang);
	    }
    }
    else {
       //document.writeln('showPopupStaticMap does not exist<br />');
       //alert("Lands Department's GIHS system is down!");   //to alert message may cause approval check.
    }
}


//-->
