Win a copy of Design for the Mind this week in the Design forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

URL Rewriting - Doubt

 
kalle suresh
Ranch Hand
Posts: 48
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
In order for session to maintain there should be an unique sessionid that will be passed every time when the user sends the request and server responds back.
In case of cookies : first time the servers creates a session id and set cookie and when the user sends the request, the request will be sent with cookie header;

In case of URL Rewriting : The server appends the session id to the url by doing response.encodeURL(...).

But how the session id will be appended to the request URL?
 
Christophe Verré
Sheriff
Posts: 14691
16
Eclipse IDE Ubuntu VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
But how the session id will be appended to the request URL?

A request parameter called "jsessionid" will be appended to the url. Here is an example from the servlets specification :

The session ID must be encoded as a path parameter in the URL string. The
name of the parameter must be jsessionid. Here is an example of a URL
containing encoded path information:
http://www.myserver.com/catalog/index.html;jsessionid=1234

[ December 03, 2007: Message edited by: Christophe Verre ]
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic