内容摘要
1.HttpSession
2.Cookie
3.URL重写
一、会话跟踪
1.为什么需要会话跟踪
(1)http协议是一种无状态的协议
(2)需要对用户在访问同一web应用是对用户进行跟踪(判断用户是否登录)
2.HttpSession
(1)HttpSession简介
Paste_Image.png
(2)HttpSession 常用方法
Paste_Image.png
Paste_Image.png
(3)使用HttpSession完成登录验证
Paste_Image.png