JSP 04课 (1)
2021-03-31 07:26
阅读:603
YPE HTML>
标签:pre rpo com his tle sep sheet path form
"java" import="java.util.*" pageEncoding="utf-8"%> String path = request.getContextPath(); String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/"; %> span>"-//W3C//DTD HTML 4.01 Transitional//EN">base href="">My JSP ‘login.jsp‘ starting page "pragma" content="no-cache"> "cache-control" content="no-cache"> "expires" content="0"> "keywords" content="keyword1,keyword2,keyword3"> "description" content="This is my page">
"java" import="java.util.*" pageEncoding="utf-8"%> String path = request.getContextPath(); String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/"; %> span>"-//W3C//DTD HTML 4.01 Transitional//EN"> base href="">My JSP ‘welcome.jsp‘ starting page "pragma" content="no-cache"> "cache-control" content="no-cache"> "expires" content="0"> "keywords" content="keyword1,keyword2,keyword3"> "description" content="This is my page">"center">你好!Lucky!
"java" import="java.util.*" pageEncoding="utf-8"%> String path = request.getContextPath(); String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/"; %> span>"-//W3C//DTD HTML 4.01 Transitional//EN"> base href="">My JSP ‘doLogin.jsp‘ starting page "pragma" content="no-cache"> "cache-control" content="no-cache"> "expires" content="0"> "keywords" content="keyword1,keyword2,keyword3"> "description" content="This is my page"> request.setCharacterEncoding("utf-8"); String name=request.getParameter("uname"); String pwd=request.getParameter("upwd"); if(name.equals("lucky")&&pwd.equals("123456")){ request.getRequestDispatcher("welcome.jsp").forward(request,response); }else{ request.getRequestDispatcher("login.jsp").forward(request,response); } %>
JSP 04课 (1)
标签:pre rpo com his tle sep sheet path form
原文地址:https://www.cnblogs.com/naoguakerteng/p/12587840.html
评论
亲,登录后才可以留言!