Sessions

Sodapop gives developers the choice of using PHP's builtin $_SESSION array or its own Sodapop_Session object.

The Sodapop_Request object is accessed statically. Generally, it is best to store scalar and array objects in Sessions rather than objects due to PHP's requirement that classes stored in the session be defined before session_start() is first called. Sodapop's dynamic nature makes this difficult to guarantee.

Public Methods

delete($key) (void)
Deletes a key from the session.
destroy() (void)
Destroys the session.
exists($key) (boolean)
Returns true if the named property exists in the session and false otherwise.
get($key) (mixed)
Returns the named property from the session, and null if it isn't found.
set($key, $value) (void)
Adds a new value to the session for the provided key.