摘要:
goods.jsp<%@ page language="java" contentType="text/html; charset=gb2312" pageEncoding="gb2312"%><!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"><html><head><meta http-e
阅读全文
摘要:
数据库脚本:create database user_logingo use user_logingocreate table tb_user( id int identity(1,1) primary key, username varchar(20) not null, password varchar(20) not null, sex varchar(4) not null, question varchar(20), answer varchar(20), email varchar(20))set identity_insert tb_user on//可以显示插入自增字段的值in
阅读全文
摘要:
web.xml配置信息 <filter> <filter-name>Myfilter</filter-name> <filter-class>com.filter.Myfilter</filter-class> <init-param> <param-name>encoding</param-name> <param-value>gb2312</param-value> </init-param> </filter> <filter-mappin
阅读全文
摘要:
servlet请求页面:一直要注意路径问题,如果写成是/SimpleServlet则会到http://localhost:8080/SimpleServlet进行查找,而需要加 "."代表当前路径下查找就可以了。<form action="./SimpleServlet" method="post"> <input type="submit" name="submit" value="提交"> </form>web.xml配置信息如下。&l
阅读全文