actual_counts() public method

public actual_counts ( $profile_id = false, $context = 'profile' )
コード例 #1
0
function get_media_counts()
{
    global $rtmedia_query;
    $user_id = false;
    if (function_exists("bp_displayed_user_id")) {
        $user_id = bp_displayed_user_id();
    } else {
        if (isset($rtmedia_query) && isset($rtmedia_query->query['context_id']) && $rtmedia_query->query['context'] == "profile") {
            $user_id = $rtmedia_query->query['context_id'];
        }
    }
    $media_nav = new RTMediaNav(false);
    $user_media_counts = $media_nav->get_counts($user_id);
    //var_dump($user_media_counts);
    $temp = $media_nav->actual_counts($user_id);
    return $temp;
    //return $user_counts;
}
コード例 #2
0
ファイル: rtmedia-functions.php プロジェクト: rtCamp/rtMedia
/**
 * Get media counts
 *
 * @global      RTMediaQuery        $rtmedia_query
 *
 * @return      array|void
 */
function get_media_counts()
{
    global $rtmedia_query;
    $user_id = false;
    if (function_exists('bp_displayed_user_id')) {
        $user_id = bp_displayed_user_id();
    } else {
        if (isset($rtmedia_query) && isset($rtmedia_query->query['context_id']) && 'profile' === $rtmedia_query->query['context']) {
            $user_id = $rtmedia_query->query['context_id'];
        }
    }
    $media_nav = new RTMediaNav(false);
    $temp = $media_nav->actual_counts($user_id);
    return $temp;
}