\User_Middleware_Session

User session

Allow a session object in the request and the automatic login/logout of a user if a standard authentication against the User model is performed.

Summary

Methods
Properties
Constants
process_request()
process_response()
$session_key
No constants found
No protected methods found
No protected properties found
N/A
No private methods found
No private properties found
N/A

Properties

$session_key

$session_key : 

کلد جلسه کاربر را تعیین می‌کند.

Type

Methods

process_request()

process_request(  $request) : boolean

Process the request.

When processing the request, if a session is found with User creditentials the corresponding user is loaded into $request->user.

FIXME: We should logout everybody when the session table is emptied.

Parameters

$request

Returns

boolean —

false

process_response()

process_response(  $request,   $response) : \Pluf_HTTP_Response

Process the response of a view.

If the session has been modified save it into the database. Add the session cookie to the response.

Parameters

$request
$response

Returns

\Pluf_HTTP_Response

The response