agregar clases de rol al body en wordpress

Solutions on MaxInterview for agregar clases de rol al body en wordpress by the best coders in the world

showing results for - "agregar clases de rol al body en wordpress"
Tommaso
14 Jan 2018
1add_filter( 'body_class', function( $classes ){
2    foreach( (array) wp_get_current_user()->roles as $role ){
3        $classes[] = "role-$role";
4    }
5    return $classes;
6});
7