Sub iCard_Hidden() if Lcase(TypeName(document.getElementById("iCard")))="htmldivelement" then document.body.RemoveChild(iCard) end if End Sub Sub ShowCard(sUserName,sButtons) 'on error resume next dim RequestURL,objTemp,tempStr if sUserName="" then Alert("用户名参数错误!") else if Lcase(TypeName(document.getElementById("iCard")))="htmldivelement" then document.body.RemoveChild(iCard) end if Set objTemp=document.createElement("div") objTemp.id="iCard" With objTemp .style.cssText="position: absolute; left: 100; top: 1; z-index: 1;cursor:default" .style.top=window.event.Y+document.body.scrollTop+10 .style.left=Window.event.X+document.body.scrollleft+0 End With document.body.appendChild objTemp Set objTemp=Nothing Set objTemp=document.createElement("div") With objTemp .id="iCardInfo" .innerHTML="正在加载信息..." .onclick=GetRef("iCard_Hidden") End With iCard.appendChild objTemp Set objTemp=Nothing RequestURL="/vRegUser/iCard/iCard.asp?UserName="&sUserName iCardInfo.innerHTML=SendCMD_CN(RequestURL) if sButtons<>"" then sButtons=Lcase(sButtons) if InStr(sButtons,"btnsendmail")>0 then tempStr="" end if if InStr(sButtons,"btnaddfriend")>0 then tempStr=tempStr&"" end if Set objTemp=document.createElement("div") With objTemp .id="iCardBTN" .innerHTML="

"&tempStr&"

" End With iCard.appendChild objTemp Set objTemp=Nothing end if end if End Sub