解决方案 »

  1.   

    http://go4.163.com/~blueski/
    下个虚拟小龙亭去看看
      

  2.   

    可以用SESSION
    <%@ page import="java.lang.*" %>
    <%@ page import="java.io.*" %>
    <%@ page import="javax.rmi.PortableRemoteObject" %>
    <%@ page import="javax.naming.InitialContext" %>
    <%@ page import="commonHome" %>
    <%@ page import="commonRemote" %><%--  String Error_message= req.getParameter("error");--%>
    <%
          commonRemote common;
          InitialContext ic = new InitialContext();
          Object objref_find = ic.lookup("java:comp/env/ejb/common");            
          commonHome home_find=(commonHome)PortableRemoteObject.narrow(objref_find,commonHome.class);
          common=home_find.create();
          
          //HttpSession session = request.getSession(true);
          session.setAttribute("common",common);   
    %>           
    <html>
    <head>
       <title>用户登录</title>
       <meta HTTP-EQUIV="Content-Type" Content="text-html; charset=GB2312">
    </head>
    <body>
    <center>
    <form name=form1 action=update method=post>
    KONICA PARTS SYSTEM
    <p>
    用户登录
    <p>
    <%
       String Error_message=request.getParameter("error");
       if (Error_message!=null)
       {
    %>
           错误信息:<%=new String(Error_message.getBytes("gb2312"),"8859_1")%>
    <%
       }
    %>
    <p>
    <table border>
    <tr>
        <td>用户号</td>
        <td><input name=code value=""></td>
    </tr>
    <tr>
        <td>密码</td>
        <td><input name=password value=""></td>
    </tr>
    <tr>
        <td><input type="submit" value="更新"></td>
        </form>
        <form name="form2" action="register" method="post">
        <td><input type="submit" value="注册"></td>
        </form>
        <form name="form3" action="special_register" method="post">
        <td><input type="submit" value="特殊用户注册"></td>
        </form>
    </tr>
    </table>
    </center>
    </body>
    </html>
      

  3.   

    用不用session是什么意思?
    客户端与服务器端交互就会产生一个session,
    建义将用户ID放入session中进行传递
      

  4.   

    用Session做用户认证是有个问题在CSDN这里几乎一直没有人能给出解决方法。
    就是用户非正常退出,SESSION仍然保留了下来,如何处理???!!!
      

  5.   

    removeAttribute(java.lang.String name) 
              Removes the object bound with the specified name from this session.