APM: Cookie-less cgi sessions

Taylor Carpenter taylor at codecafe.com
Wed Sep 22 13:54:13 CDT 2004


On Wed, 22 Sep 2004 13:01:20 -0500, "Sam Foster"
<austin.pm at sam-i-am.com> said:
> Scanning CGI::Session's perldocs, it looks to rely on http cookies. Is 
> there another module anyone can recommend that gives you options (e.g. 
> adding the session id to the querystring, or a hidden field) or better 
> yet will pick the appropriate or available mechanism invisibly?
> 
> Sorry my searching has not been exhaustive - I just figured this might 
> be a easy one for someone out there to get me on the right track.


Hello Sam,

CGI::Session also supports using query string to pass the session ID. 
It will do this automatically.

>From the page

http://search.cpan.org/~sherzodr/CGI-Session-3.95/Session/Tutorial.pm#WHAT_YOU_NEED_TO_KNOW_FIRST

It discusses the second argument to CGI::Session.

"In this case, the library will try to retrieve the session id from
either CGISESSID cookie or CGISESSID CGI parameter (query string)"

Hope this helps.

On a side note... It is very easy to extend CGI::Session for storage
methods and session ID generation.

Taylor


More information about the Austin mailing list