php - Same URL for multiple routes -


how can same url pointing different controllers depending on user role ?

for instance /route1 should poiting on admin\route1controller@index if user has admin role, , otherrole\route1controller@index if user has otherrole role.

how can done ?

you can achieve using middleware in routes.php file creating roles using roman bican roles package in laravel.


Comments

Popular posts from this blog

Sass watch command compiles .scss files before full sftp upload -

filehandler - java open files not cleaned, even when the process is killed -

gridview - Yii2 DataPorivider $totalSum for a column -