This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
function get_all_users_id_by_membership_level_id() { | |
$memberships = rcp_get_memberships( array( | |
'status' => 'active', | |
'object_id' => 2 // Membership Levels ID | |
) ); | |
foreach ($memberships as $membership) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
function random_user_query( &$query ) | |
{ | |
$query->query_orderby = "ORDER BY RAND()"; | |
} | |
function display_random_vip_users( $atts ) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
function get_all_activity_ids_type_is_new_avatar(){ | |
global $wpdb, $bp; | |
// Prepare Sql | |
$sql = $wpdb->prepare( "SELECT id FROM {$bp->activity->table_name} WHERE type = %s AND component = '%s'", 'new_avatar' , 'profile' ); | |
// Get Result |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
add_filter('yz_get_profile_hidden_widgets','hide_widgets_from_user_profile_edit_section'); | |
function hide_widgets_from_user_profile_edit_section( $widget ) { | |
$widget[] = 'portfolio'; | |
return $widget; |
OlderNewer