Is a Session ID generated on the Server-side or Client-side?

前端 未结 4 531
盖世英雄少女心
盖世英雄少女心 2021-01-06 14:44

This web page http://www.w3schools.com/ASP/prop_sessionid.asp states that a session ID is generated on the ServerSide.

If this is the case, then how does a server kn

4条回答
  •  时光说笑
    2021-01-06 15:18

    The session ID is normally generated on the server. It's then sent to the client, either as a cookie in the HTTP headers, or by including it in the HTML, i.e. the links become href=my.html?sessionid=1234.

    The client's next request will then contain the session Id, either in the cookie or the GET part of the request.

提交回复
热议问题