Join the social network of Tech Nerds, increase skill rank, get work, manage projects...
 
  • CakePHP built-in sessions

    • 0
    • 1
    • 0
    • 1
    • 0
    • 0
    • 0
    • 0
    • 166
    Comment on it

    CakePHP have several In-built sessions configurations. We can use these sessions as the basis or can create a fully custom solution for that. To use defaults inbuilt sessions, we can simply set the defaults key to the name and can override any setting in Session config by the code-

    Configure::write('Session', array(
    'defaults' => 'php'
    ));
    

    The above will get to use the In-built php session config. You could augment part or all of it by doing the following:

    Configure::write('Session', array(
     'defaults' => 'php', 'cookie' =>
     'my_app', 'timeout' => 4320 //3 days
     ));
    

    Built in sessions are ->

    Session Handlers-> Session handler is also known as session config array. When they are defined ,they allow us to map the various session_save_handler values to a class.

    Database sessions The changes in session configuration change how you define database sessions.

    Cache Sessions The Cache is used to store sessions. This allows us to store sessions in a cache.

 0 Comment(s)

Sign In
                           OR                           
                           OR                           
Register

Sign up using

                           OR                           
Forgot Password
Fill out the form below and instructions to reset your password will be emailed to you:
Reset Password
Fill out the form below and reset your password: