Difference between #4 and #5 of
How to login from different tables in Yii2

Revision #5 has been created by AndroideLP on Apr 3, 2018, 11:36:02 PM with the memo:

error code php
« previous (#4) next (#6) »

Changes

Title unchanged

How to login from different tables in Yii2

Category unchanged

How-tos

Yii version unchanged

2.0

Tags unchanged

authentication,login,different table name,multiple login

Content changed

[...]
];
}

```
To use login:

 
```php
 
//school
\Yii::$app->scholl->login($model, $this->rememberMe ? 3600*24*30 : 0);
[...]
```

 
 
For restrict access in views:

```php

<?php if (!\Yii::$app->scholl->isGuest):?>
<h1>My scholl Name: <?=\Yii::$app->scholl->identity->name?>
[...]
5 0
6 followers
Viewed: 64 392 times
Version: 2.0
Category: How-tos
Written by: AndroideLP
Last updated by: lenovo
Created on: Apr 3, 2018
Last updated: 4 years ago
Update Article

Revisions

View all history