Created
January 8, 2017 08:28
-
-
Save Mamaduka/3871476ad8dcd397eda21b7b5aa69580 to your computer and use it in GitHub Desktop.
This file contains hidden or 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 mamaduka_register_bp_component( $components, $type ) { | |
// Only display custom component when viewing 'All' and 'Optional'. | |
if ( ! in_array( $type, array( 'all', 'optional' ) ) ) { | |
return $components; | |
} | |
$components[] = array( | |
'bp-select-home' array( | |
'title' => __( 'Select Home', 'fp-stroke-community' ), | |
'descripttion' => __( 'Component description here', 'fp-stroke-community' ), | |
) | |
); | |
return $components; | |
} | |
add_filter( 'bp_core_get_components', 'mamaduka_register_bp_component', 10, 2 ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment