2017 © Pedro Peláez
 

library yii2-file-session

Extention Class for Yii2 File Session based on yii/web/Session

image

alexdin/yii2-file-session

Extention Class for Yii2 File Session based on yii/web/Session

  • Tuesday, August 22, 2017
  • by alexdin
  • Repository
  • 1 Watchers
  • 2 Stars
  • 5 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 3 Versions
  • 25 % Grown

The README.md

yii2-file-session

PHP Yii2. This is an expanding class of web sessions . This class supports retrieving data on session id and deleting it., (*1)

Installation

php composer.phar require --prefer-dist alexdin/yii2-file-session

or add, (*2)

"alexdin/yii2-file-session":"^0.0.2"

Configure

Configure file session add this string to components in config main.php file (main-local.php)., (*3)

 'session' => [
             // this is the name of the session cookie used for login on the backend
             'class'=>'alexdin\filesession\Session',
             'name' => 'session-name',
             // dir for your path session
             // create migrate if dir is not exists or use "mkdir" function
             'savePath' => __DIR__ . '/../runtime/sessions',
         ],
 ```
 Usage
 -----

```php
Yii::$app->session->destroySession($id)

Clears and deletes the session by id, (*4)

Yii::$app->session->readSession($id)

Reads the session from the file and returns the serialized data in the string, (*5)

Yii::$app->session->getSessionData($id)

Returns an array of session data by id, (*6)

Yii::$app->session->getSessionFileName($id)

Returns the session file name by id, (*7)

The Versions

22/08 2017

dev-master

9999999-dev

Extention Class for Yii2 File Session based on yii/web/Session

  Sources   Download

The Requires

 

by Alexey Dinachuk

yii2 session alexdin file-session multi-session

21/08 2017

0.0.2

0.0.2.0

Extention Class for Yii2 File Session based on yii/web/Session

  Sources   Download

The Requires

 

by Alexey Dinachuk

yii2 session alexdin file-session multi-session

21/08 2017

0.0.1

0.0.1.0

Extention Class for Yii2 File Session based on yii/web/Session

  Sources   Download

The Requires

 

by Alexey Dinachuk

yii2 session alexdin file-session multi-session