日期:2014-05-17 浏览次数:20700 次
<%@ page contentType="text/html" pageEncoding="UTF-8" %> <%@ page import="java.util.*"%> <html> <body> <form name="form1" method="post" action="instring.jsp"> <input type="text" name="js"> <input type ="submit" name ="submit" value="提交"> </form> <%!String s=null;%> <% request.setCharacterEncoding("utf-8"); s=request.getParameter("js"); if(s==null) { out.println("你输人的是空字符串!"); } else { out.println("你输入的是:"+s); } %> </body> </html>