The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.

NAME

OpenFrame::Slot::Session - Handle cookie-based sessions

SYNOPSIS

  # as part of the SLOTS entry in OpenFrame::Config:
  {
  dispatch => 'Local',
  name     => 'OpenFrame::Slot::Session',
  config   => {
    default_session => {
      language => 'en',
      country  => 'UK',
      application => {},
      },
    },
  },

DESCRIPTION

OpenFrame::Slot::Session is an OpenFrame slot that can handle cookie-based session handling.

Apart from adding it as a SLOT early on in the slot process, the handling of session is done fairly transparently.

Sessions are currently handled by the Apache::SessionX modue and are not expired. This is somewhat of a pain, as you have to set up that module properly before being able to use sessions, but this brings the advantage of transparently using the right session environment, be that static files, a BerkeleyDB file or even a database. A default session can be passed as "default_session".

After this slot is run, slots may request OpenFrame::Session objects. Applications using OpenFrame::Slot::Dispatch automatically get the session passed to them.

Any information stored in the session hash will be magically available upon the next request by the same user. This is handled behind the scenes by sending and receiving a cookie.

AUTHOR

James A. Duncan <jduncan@fotango.com>, Leon Brocard <leon@fotango.com>

COPYRIGHT

Copyright (C) 2001, Fotango Ltd.

This module is free software; you can redistribute it or modify it under the same terms as Perl itself.