bbp_is_single_view()
Check if current page is a view page
Description
Return
(bool) Is it a view page?
Source
File: bp-forums/common/template.php
function bbp_is_single_view() { global $wp_query; // Assume false $retval = false; // Check query if ( !empty( $wp_query->bbp_is_view ) && ( true === $wp_query->bbp_is_view ) ) $retval = true; // Check query name if ( empty( $retval ) && bbp_is_query_name( 'bbp_single_view' ) ) $retval = true; return (bool) apply_filters( 'bbp_is_single_view', $retval ); }
Changelog
Version | Description |
---|---|
bbPress (r2789) | 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.