L liguang Unregistered / Unconfirmed GUEST, unregistred user! 2000-05-01 #1 如何编程实现202.10.10.2转到http://www.netease.com(只是举例)。这样 的转换。
O o*o Unregistered / Unconfirmed GUEST, unregistred user! 2000-05-02 #4 function GetDomainName(Ip:string):string; var pHHostent; data:twsadata; ii:dword; begin WSAStartup($101, Data); ii:=inet_addr(pchar(ip)); pH:=gethostbyaddr(@ii,sizeof(ii),PF_INET); if (ph<>nil) then result:=pH.h_name else result:=''; WSACleanup; end;
function GetDomainName(Ip:string):string; var pHHostent; data:twsadata; ii:dword; begin WSAStartup($101, Data); ii:=inet_addr(pchar(ip)); pH:=gethostbyaddr(@ii,sizeof(ii),PF_INET); if (ph<>nil) then result:=pH.h_name else result:=''; WSACleanup; end;