F
F
First Name2017-05-19 00:14:23
Yii
First Name, 2017-05-19 00:14:23

How to do authorization/registration with roles in Yii2?

Good day to all.
You need to register / authorize on Yii2 with roles (admin / guest)
When a person logs in, he is redirected to a page that shows what role he has.
Previously, I just wanted to add the "role" field to the database and compare.
But they told me to do it in yii2 and I started googling about this frame.
Then, as I understand it, yii 2 has some kind of functionality for this.
Then I found some kind of RBAC 2
Then I found some Gii - a code generator.
Krch in a word what to google on this topic?
PS as I understand it, you need to build forms through the activeform class?
Thank you in advance for your replies and sorry for the bad description.

Answer the question

In order to leave comments, you need to log in

2 answer(s)
M
Maxim Fedorov, 2017-05-19
@qonand

But they told me to do it in yii2 and I started googling about this frame.

You would first deal with the framework itself, for example, according to this documentation
Understand RBAC The internet is full of articles on this topic.

D
Dmitry, 2017-05-19
@slo_nik

Good morning.
I will add a link to what Maxim Fedorov wrote .
Check out the article at the link, and even better, with all the previous articles with the yii2 tag

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question