function getPageHTML(url,element_id,text_rule)
  {
  var xmlHttp;
  try
    {
    // Firefox, Opera 8.0+, Safari
    xmlHttp=new XMLHttpRequest();
    }
  catch (e)
    {
    // Internet Explorer
    try
      {
      xmlHttp=new ActiveXObject("Msxml2.XMLHTTP");
      }
    catch (e)
      {
      try
        {
        xmlHttp=new ActiveXObject("Microsoft.XMLHTTP");
        }
      catch (e)
        {
        alert("Your browser does not support AJAX!");
        return false;
        }
      }
    }
    xmlHttp.onreadystatechange=function()
      {
      if(xmlHttp.readyState==4)
        {
        	HtmlTxt=xmlHttp.responseText;
        	if(text_rule=="replace"){
        		document.getElementById(element_id).innerHTML=HtmlTxt;
        	}else if(text_rule=="append"){
        		document.getElementById(element_id).innerHTML=document.getElementById(element_id).innerHTML + HtmlTxt;
        	}else if(text_rule=="prepend"){
        		document.getElementById(element_id).innerHTML=HtmlTxt + document.getElementById(element_id).innerHTML;
        	}
        }
      }
    xmlHttp.open("GET",url,true);
    xmlHttp.send(null);
  }
  
  
  function setContentHTML(HtmlTxt,element_id,text_rule)
  {
		if(text_rule=="replace"){
			document.getElementById(element_id).innerHTML=HtmlTxt;
		}else if(text_rule=="append"){
			document.getElementById(element_id).innerHTML=document.getElementById(element_id).innerHTML + HtmlTxt;
		}else if(text_rule=="prepend"){
			document.getElementById(element_id).innerHTML=HtmlTxt + document.getElementById(element_id).innerHTML;
		}else if(text_rule=="" || text_rule==null){
			document.getElementById(element_id).innerHTML=HtmlTxt;
		}
  }

  
  function getPageHtmlandExecuteCommand(url,element_id,text_rule,funcName)
  {
  var xmlHttp;
  try
    {
    // Firefox, Opera 8.0+, Safari
    xmlHttp=new XMLHttpRequest();
    }
  catch (e)
    {
    // Internet Explorer
    try
      {
      xmlHttp=new ActiveXObject("Msxml2.XMLHTTP");
      }
    catch (e)
      {
      try
        {
        xmlHttp=new ActiveXObject("Microsoft.XMLHTTP");
        }
      catch (e)
        {
        alert("Your browser does not support AJAX!");
        return false;
        }
      }
    }
    xmlHttp.onreadystatechange=function()
      {
      if(xmlHttp.readyState==4)
        {
        	HtmlTxt=xmlHttp.responseText;
        	if(text_rule=="replace"){
        		document.getElementById(element_id).innerHTML=HtmlTxt;
        	}else if(text_rule=="append"){
        		document.getElementById(element_id).innerHTML=document.getElementById(element_id).innerHTML + HtmlTxt;
        	}else if(text_rule=="prepend"){
        		document.getElementById(element_id).innerHTML=HtmlTxt + document.getElementById(element_id).innerHTML;
        	}	
			eval(funcName);
        }
      }
    xmlHttp.open("GET",url,true);
    xmlHttp.send(null);
  }