whois in jsp (我在网上找的,充实一下这里)
类别: JAVA教程
<%@page import="java.io.*,java.net.*"%>
<%
Socket whois=new Socket("whois.networksolutions.com",43);
InputStream in=whois.getInputStream();
DataOutputStream data_out=new DataOutputStream(whois.getOutputStream());
data_out.writeBytes("yahoo.com/r/n");
int d;
while(true){
d=in.read();
if(d<0)
break;
out.print((char)d);
}
data_out.close();
in.close();
%>
<%
Socket whois=new Socket("whois.networksolutions.com",43);
InputStream in=whois.getInputStream();
DataOutputStream data_out=new DataOutputStream(whois.getOutputStream());
data_out.writeBytes("yahoo.com/r/n");
int d;
while(true){
d=in.read();
if(d<0)
break;
out.print((char)d);
}
data_out.close();
in.close();
%>
-= 资 源 教 程 =-
文 章 搜 索