var xmlHttp
var tab = 2;
function special(id)
{ 

xmlHttp=GetXmlHttpObject();
if (xmlHttp==null)
  {
  alert ("Your browser does not support AJAX!");
  return;
  } 
  
var url="special.php";
url=url+"?idx="+id;
url=url+"&sid="+Math.random();
for (i =1; i<6; i++){
document.getElementById("minitab"+i).style.background = "url('images/inactiveminitab.gif')";
}
document.getElementById("minitab"+id).style.background = "url('images/activeminitab.gif')";
xmlHttp.onreadystatechange=stateChanged;
xmlHttp.open("GET",url,true);
xmlHttp.send(null);
tab = id;
if (tab==5){
    tab = 0;
}
tab++;

 clearTimeout(to);
to = setTimeout('special(tab)', 6000);

}
to = setTimeout('special(tab)', 6000);

function stateChanged() 
{ 
    if (xmlHttp.readyState==4)
    {
    	
    	//alert(xmlHttp.responseText);
        document.getElementById("special").innerHTML=xmlHttp.responseText;
    }
}

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;
}