zoukankan      html  css  js  c++  java
  • 每日博客

    时间:上午8:50-9:50,下午4:00-6:00

    代码:200多行?

    博客:1

    知识点:web,数据库,html

    <%@ page language="java" contentType="text/html; charset=UTF-8"
        pageEncoding="UTF-8"%>
    <!DOCTYPE html>
    <html>
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
    <title>Insert title here</title>
    </head>
    <body>
    <%
    String name=request.getParameter("name");
    String pwd=request.getParameter("pwd");
    if(name!=null&&pwd!=null&&name.equals("jsj")&&pwd.equals("123")){
    %>
    <jsp:forward page="success.jsp"/>
    <% 
    }else{response.sendRedirect("fail.html");} 
    %>
    </body>
    </html>
    <%
     Object oCount = application.getAttribute("count");
     Integer count=null;
     if(oCount==null)
     {
      count = new Integer(1);   
      application.setAttribute("count", count);
     }
     else
     {
      count = (Integer)application.getAttribute("count");
      count = new Integer(count.intValue()+1);  
      application.setAttribute("count", count);
     }
     %>
    这是第<%=count.intValue() %>次登录。
    <%
     Object oCount = application.getAttribute("count");
     Integer count=null;
     if(oCount==null)
     {
      count = new Integer(1);   
      application.setAttribute("count", count);
     }
     else
     {
      count = (Integer)application.getAttribute("count");
      count = new Integer(count.intValue()+1);  
      application.setAttribute("count", count);
     }
     %>
    这是第<%=count.intValue() %>次登录。
    <%request.setCharacterEncoding("utf-8");%>
    <%=(String)session.getAttribute("flag")%>
  • 相关阅读:
    [转载]数据类型和Json格式 Joe
    为页面去掉下划线
    基于Spring,struts,hibernate的JYazd仿yazd及jivejdon
    tomcat下建立虚拟目录
    用例建模指南
    王老师好,学生请教个设计上的问题
    博客第一个处女作,顺便测试一下
    自定义可以和with一起工作的类
    boost cpu_timer
    静态初始化的相依性
  • 原文地址:https://www.cnblogs.com/hfy717/p/14579236.html
Copyright © 2011-2022 走看看