bp_nouveau_get_search_primary_object( string $object = '' )
Get the search primary object
Description
Parameters
- $object
-
(Optional) The primary object.
Default value: ''
Return
(string) The primary object.
Source
File: bp-templates/bp-nouveau/includes/template-tags.php
1755 1756 1757 1758 1759 1760 1761 1762 1763 1764 1765 1766 1767 1768 1769 1770 1771 1772 1773 1774 1775 | function bp_nouveau_get_search_primary_object( $object = '' ) { if ( bp_is_user() ) { $object = 'member' ; } elseif ( bp_is_group() ) { $object = 'group' ; } elseif ( bp_is_directory() ) { $object = 'dir' ; } else { /** * Filters the search primary object if no other was found. * * @since BuddyPress 3.0.0 * * @param string $object Search object. */ $object = apply_filters( 'bp_nouveau_get_search_primary_object' , $object ); } return $object ; } |
Changelog
Version | Description |
---|---|
BuddyPress 3.0.0 | 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.