Professional Documents
Culture Documents
Week 9 - T
Week 9 - T
Week 9 - T
Languages and
Technologies
Bruno Veloso
brunov@upt.pt
23/09/2018
IMP.GE.190.0
2
Apache PHP
HTML DB
HTTP
IMP.GE.190.0
Response
3
IMP.GE.190.0
4
IMP.GE.190.0
5
HTTP is stateless?
UPT
• Each colour, for all intents and purposes, represents a new client
for the server.
IMP.GE.190.0
6
IMP.GE.190.0
7
GET /index.html
HTTP/1.1
Host: www.upt.pt
HTTP/1.1 200 OK
Content-type: text/html
UPT Set-Cookie: name=value
Set-Cookie:
name2=value2
Cookies – Attributes
IMP.GE.190.0
9
IMP.GE.190.0
10
IMP.GE.190.0
11
Two Ways
• Session Cookies:
• Cookies which the browser will automatically eliminate
once it is closed.
• Do not mistake with Sessions!
IMP.GE.190.0
12
Session
IMP.GE.190.0
13
IMP.GE.190.0
14
IMP.GE.190.0