Search
 
SCRIPT & CODE EXAMPLE
 

PHP

Agregar clases de rol al body en WordPress

add_filter( 'body_class', function( $classes ){
    foreach( (array) wp_get_current_user()->roles as $role ){
        $classes[] = "role-$role";
    }
    return $classes;
});
Comment

PREVIOUS NEXT
Code Example
Php :: js data php 
Php :: codeigniter email validate and dublicate from database in php 
Php :: create global function laravel 
Php :: validate unique or equal 
Php :: whats is typecasting in php 
Php :: if no data show msg and chang style laravel 
Php :: set php variabe with javascript loca storage 
Php :: create json file in php and write n php 
Php :: base64 to arraybuffer php 
Php :: bootstrap carousel foreach loop not working wordpressp php wp 
Php :: $order- date 
Php :: phpunit run group 
Php :: php curl upload linkedin image 
Php :: laravel get relation camelcase api 
Php :: How to check if fwrite failed php 
Php :: add element to this array 
Php :: auto complete order paid 
Php :: image_store 
Php :: PhpDebugBar is not defined nginx 
Php :: Détecter les utilisateurs mobiles 
Php :: php get last 4 digits of string 
Php :: laravel get referer without host 
Php :: Dein Benutzer-Profil um weitere Social Media Accounts erweitern 
Php :: how to add posts to php 
Php :: php division without round 
Php :: how to reduce time taken by php script on server 
Php :: veue laravel remove #/ 
Php :: Add laravel sail build as alias 
Php :: fuzzy search in php with percentage 
Php :: wp woocommerce change product tags to checbox 
ADD CONTENT
Topic
Content
Source link
Name
5+4 =