<html>
<head>
<title>map</title>
</head>
<body>
<%
String getvalue;
getvalue=request.getParameter("select");
这块怎样用java下面的类实现发送字符串getvalue?
不知道这块怎么写?
%>
</body>
</html>
import java.io.*;
import java.net.*;
public class Client
{
public void SendData()
{
Socket clientSock=null;
try
{
clientSock=new Socket("127.0.0.1",10000);
if(clientSock!=null)
{
out.println("now,the state is connected!");
}
PrintWriter sockOutput= new PrintWriter(clientSock.getOutputStream());
sockOutput.println(getvalue);
sockOutput.flush();
}
catch(Exception e)
{
e.getStackTrace();
}
}
public static void main(String args[])
{
Client c=new Client();
c.SendData();
}
}