// Start XmlHttp Object
function uzXmlHttp(){
    var xmlhttp = false;
    try{
        xmlhttp = new ActiveXObject("Msxml2.XMLHTTP");
    }catch(e){
        try{
            xmlhttp = new ActiveXObject("Microsoft.XMLHTTP");
        }catch(e){
            xmlhttp = false;
        }
    }

    if(!xmlhttp && document.createElement){
        xmlhttp = new XMLHttpRequest();
    }
    return xmlhttp;
}
// End XmlHttp Object
function getresult(platform,type,row,col,bg,font){
//alert(x);
	var bgs = bg.replace("#", "");
	var fonts = font.replace("#", "");
	
	if(platform == '1'){
  		//var url = 'http://www.bluegy.com/services/news_service_detail.php?type='+type+'&row='+row+'&col='+col+'&bg='+bgs+'&font='+fonts;
		if(type == '92'){
  			var url = 'http://asiaidol.bluegy.com/news_service_detail.php?type='+type+'&row='+row+'&col='+col+'&bg='+bgs+'&font='+fonts;
		}
		else{
			var url = 'http://www.bluegy.com/services/news_service_detail.php?type='+type+'&row='+row+'&col='+col+'&bg='+bgs+'&font='+fonts;

		}
		    
  	}
	else {
		if(type == '92'){
  			var url = 'http://asiaidol.bluegy.com/news_service_detail_text.php?type='+type+'&row='+row+'&col='+col+'&bg='+bgs+'&font='+fonts;   
		}
		else{
			var url = 'http://www.bluegy.com/services/news_service_detail_text.php?type='+type+'&row='+row+'&col='+col+'&bg='+bgs+'&font='+fonts;   

		}		
  		//var url = 'http://www.bluegy.com/services/news_service_detail_text.php?type='+type+'&row='+row+'&col='+col+'&bg='+bgs+'&font='+fonts;    
	}
	
	
	var n = 'frameContent';
	var w= '100%';
	if(platform == '1'){
			var h= row*85;

	}
	else{
			var h= row*col*20;

	}
	var bor= '0';
	var idf = "frameContent";
         document.write('<ifr' + 'ame' +
                     ' name=' + n +
					 ' id=' + idf +
                     ' width=' + w+
                     ' frameborder=' + bor +
                     ' src=' + url +
                     ' marginwidth="0"' +
                     ' marginheight="0"' +
                     ' vspace="0"' +
                     ' hspace="0"' +
                     ' allowtransparency="true"' +
                     ' scrolling="no">');
      document.write('</ifr' + 'ame>');
	  
		parent.window.document.getElementById("frameContent").height = h ;
   /*
   var result; 
	if(platform == '1'){
  		var url = 'http://www.bluegy.com/services/news_service_detail.php?type='+type+'&row='+row+'&col='+col+'&bg='+bg+'&font='+font;
		    
  	}
	else {
  		var url = 'http://www.bluegy.com/services/news_service_detail_text.php?type='+type+'&row='+row+'&col='+col+'&bg='+bg+'&font='+font;    
	}
    xmlhttp = uzXmlHttp();
    //xmlhttp.open("GET", url, false);
	xmlHttp.open("GET", 'http://www.bluegy.com/services/transport.php?action='+urlencode('different-server.com/return_call.php')+'&method=get&data1=101&data2=pass', true );
    xmlhttp.send(null); 
    // รับค่ากลับจาก server มาเก็บลง result
    result = xmlhttp.responseText;
    // นำค่าที่ได้ออกไปแสงผล
	//data_service.style.textDecoration = none;
	
	document.getElementById("data_service").innerHTML = result;
	document.getElementById("data_service").style.textDecoration="none";
	*/

}
// End XmlHttp Object





