<? function IsOnline($uin) { $fs=fsockopen('status.icq.com', 80); if(! $fs) return false; fwrite($fs, "GET http://status.icq.com/online.gif?icq=220052&img=5 HTTP/1.0\r\nHost: status.icq.com\r\n\r\n"); $str=''; while(!feof($fs)) $str.=fgets($fs); if(strstr($str,'0.gif')) return 'offline'; if(strstr($str,'1.gif')) return 'online'; if(strstr($str,'2.gif')) return 'undef'; } ?>