function showpage(add,obj){

 	
  //else if (add.substr(0,12) == 'sec-news.php') document.title='';
//alert(add) ;
  objj=obj;
  xmlHttp=GetXmlHttpObject();
  if (xmlHttp==null)  { 
       alert ("پشتيباني نمي كند HTTP Request مرورگر شما از");
    return ;
  } 
 var url=add;  
  xmlHttp.onreadystatechange=stateChanged ;	  
  xmlHttp.open("GET",url,true);
  xmlHttp.send(null);  
  	 
}
//********************

//********************
function GetXmlHttpObject()
{
	var xmlHttp=null;
	try{
		  // Firefox, Opera 8.0+, Safari
		  xmlHttp=new XMLHttpRequest();
	}
	catch (e){
	    // Internet Explorer
		try{
			xmlHttp=new ActiveXObject("Msxml2.XMLHTTP");
		}
		catch (e){
			xmlHttp=new ActiveXObject("Microsoft.XMLHTTP");
		}
	}
	return xmlHttp;
}
//********************




//********************
function stateChanged()
{ 
  if (xmlHttp.readyState==4 || xmlHttp.readyState=="complete")
  { 
     if(xmlHttp.status == 200) {
       document.getElementById(objj).innerHTML=xmlHttp.responseText;

     } else {
	   if (xmlHttp.status==12029) 
	      document.getElementById(objj).innerHTML='<div align="center" ><br><font dir="rtl" size="1" color="#ab0a0a" face="Tahoma">دسترسي به سرور به دليل قطع ارتباط ميسر نيست.</font></div>';
	   else
		  document.getElementById(objj).innerHTML='<div align="center" ><br><font dir="rtl" size="1" color="#ab0a0a" face="Tahoma">خطاي شماره '+xmlHttp.status +'، پيغام: '+xmlHttp.statusText+'</font></div>';
	  }  
  }
 else{
          //document.getElementById(objj).innerHTML='<div style="color:#666666; padding-top:10px; padding-bottom:9px; direction:rtl; font-size:10px; text-align:center"><img src="images/icon-wait.gif" align="middle"/><br>در حال فراخواني...</div>';
		  
  document.getElementById(objj).innerHTML='<center> <img aling="center" src="images/icons/ajax-loading.gif" /> </center>';


  }

} 
//********************

