Drupal get roles of current user

Code:

       $current_user = \Drupal::currentUser();
       $roles = $current_user->getRoles();

       // print_r( $roles );

 

Neuen Kommentar schreiben

CAPTCHA
This question is for testing whether or not you are a human visitor and to prevent automated spam submissions.

Suche

Neueste Kommentare