GetParameter gets all of the string types. Or is it the http://a.jsp tutorial? id=123 123, or a form that submits past data.
GetParameter: When used for client redirection, a link is clicked or a newsletters value is submitted, which is used to receive data when the value is passed with the form or URL redirection.
GetParameter is only the application server when you analyze the text of the request page you sent, get the value that you made when you set the form or URL redirect
-->
<%@ page contenttype= "text/html; charset=gb2312 "language=" java "import=" java.sql.* "errorpage=" "%>"
<!doctype HTML PUBLIC "-//W3C//DTD XHTML 1.0 transitional//en" "http://www.w3.org/tr/xhtml1/dtd/ Xhtml1-transitional.dtd ">
<connector port= "8080" protocol= "http/1.1" uriencoding= "Utf-8"
connectiontimeout= "20000"
redirectport= "8443"/>
<!--
The special cause of my attention is uriencoding= "Utf-8", if not set, the URL passed on the Chinese can not be correctly decoded
-->
<body>
<%
string s = Request.getparameter ("s");
String str = Request.getparameter ("Nau");
Out.println (str+ "<br/>");
Pattern p = pattern.compile ("softname= (. *) [&$]");
Matcher m = p.matcher (str);
String softname = "";
while (M.find ()) {
Softname = M.group (1);
Out.println ("softname=" + softname);
}
Out.println (Str.replace (Softname,urlencoder.encode (Softname, "utf-8"));
%>
</body>