<%@ page language="java" import="java.util.*" contentType="text/html" pageEncoding="UTF-8"%>
在<head></head>中加入一下代碼
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
用戶登錄<br>
<hr>
<form action="loginClServlet" method="post">
<table>
<tr>
<td>用戶名:</td>
<td><input type="text" name="uName"/></td>
</tr>
<tr>
<td>密 碼:</td>
<td><input type="password" name="uPass"/></td>
</tr>
<tr>
<td><input type="submit" value="登錄"/></td>
<td><input type="reset" value="重置"/></td>
</tr>
</table>
</form>
</center>
<hr>
本文出自 “java技術社區” 博客