bbp_is_topics_created()

Check if current page shows the topics created by a Forums user (profile page)

Description

Return

(bool) True if it's the topics created page, false if not

Source

File: bp-forums/common/template.php

614
615
616
617
618
619
620
621
622
623
624
625
function bbp_is_topics_created() {
    global $wp_query;
 
    // Assume false
    $retval = false;
 
    // Check query
    if ( !empty( $wp_query->bbp_is_single_user_topics ) && ( true === $wp_query->bbp_is_single_user_topics ) )
        $retval = true;
 
    return (bool) apply_filters( 'bbp_is_topics_created', $retval );
}

Changelog

Changelog
Version Description
bbPress (r2688) Introduced.

Questions?

We're always happy to help with code or other questions you might have! Search our developer docs, contact support, or connect with our sales team.