WordPress codex for page
How to get the current page slug?
global $post; $slug = get_post( $post )->post_name;
UPLOAD YOUR SITE INTO YOUR WEB HOSTING | WEB DEVELOPMENT | WEBSITE | XAMP | HOW TO CREATE A WEBSITE. EDUCATIONAL VIDEO PARA SA GUSTO TUMUKLAS NG MGA BAGONG KAALAMAN KUNG PANU GUMAWA NG WEBSITES. PAKI-SHARE PO VIDEO NG MARAMI TAYONG MATULUNGAN AT MABIGYAN NG ONLINE SKILLS. MARAMI PA TAYONG PWEDE IBAHAGI SA INYO. LINKS:…
This plugin hasn’t been tested with the latest major releases of WordPress is showed up to my WordPress plugin after I did not update my WordPress plugins for a year I think or months and many WordPress version is released after that. This is the exact notice message displayed: This plugin hasn’t been tested with…
How check if current user has pmpro_hasMembershipLevel? Copy and paste the code below to your custom template. // $levelID is can be name or ID of the membership level // $userID is the ID of the current user pmpro_hasMembershipLevel( $levelID, $userID ); // Example if(pmpro_hasMembershipLevel('12')){ } if(pmpro_hasMembershipLevel('Gold')){ } if(pmpro_hasMembershipLevel(array('12','14','Gold'))){ }
How to add an `Add Friend` button in a custom templates? Copy the codes below. <?php if( $bp->displayed_user->id != bp_get_member_user_id() ) : ?> <div class="add-friend-btn"><?php bp_add_friend_button( bp_get_member_user_id() ); ?></div> <?php endif; ?> How to get the total friends count? Read more here https://buddypress.wp-a2z.org/oik_api/friends_get_total_friend_count/. <?php global $bp; echo bp_get_user_meta( $bp->loggedin_user->id, 'total_friend_count', true ); ?> How to…
WordPress page options resetting after pressing the enter keys and all of your settings go back to zero. This is usually this is happening when you create a custom page option in WordPress dashboard. The main reason is the reset button is declared ahead or coded before submit button. If you can see the `id=”reset”`…
Code below is to get current user ID. $user_ID = get_current_user_id(); Code below is to get all user meta. $user_meta = array_map( function( $a ){ return $a[0]; }, get_user_meta( $user_ID ) ); echo $user_meta[last_name]; echo $user_meta[description]; Output : Development Lorem ipsum dolor sit amet, nunc arcu urna, id donec. Sample array. Array ( [first_name] =>…