<script>
var online= new Array();
</script>
<!--检测是否在线-->
<script
src="http://webpresence.qq.com/getonline?Type=1&xxxxxxxx:"></script>
<script>
<!--如果离线,则显示以下内容-->
if (online[0]==0)
document.write("<a class='qqb' target=blank
href='http://wpa.qq.com/msgrd?V=1&Uin=xxxxxxxx&Site=sieye.yeah.net&Menu=no'
title='当前离线或隐身'>QQ:xxxxxxxx</a> <font
color=#00FFFF>当前离线或隐身</font>");
else
<!--如果在线,则显示以下内容-->
document.write("<a class='qqa' target=blank
href='http://wpa.qq.com/msgrd?V=1&Uin=xxxxxxxx&Site=sieye.yeah.net&Menu=no'
title='当前在线'>QQ:xxxxxxxx</a> <font
color=#FFFF00><b>当前在线</b></font>");
</script>
请将上面代码中"xxxxxxxx"替换成你要检测的QQ号。