add_action ('kleo_bp_search_form', 'kleo_bp_search_form'); add_shortcode('kleo_search_register_form', 'kleo_bp_search_form'); /* Render search form */ if (!function_exists('kleo_bp_search_form')): /** * Renders a members profile search form * @global array $bp_search_fields Options form Theme options * @param bool $show_profiles Display members carouses under the form * @param string $before_form Text to display before the form fields * @return string */ function kleo_bp_search_form ($show_profiles = false, $before_form = false) { global $bp_search_fields; if (function_exists('bp_is_active') && bp_is_active( 'xprofile' )) {} else { echo __("Please enable Buddypress and Extended profiles component for the search form!","kleo_framework"); return; } if (!isset($bp_search_fields['fields']) || count ((array)$bp_search_fields['fields']) == 0) { echo "

".__("Please configure your form fields under Sweetdate - Buddypress", 'kleo_framework')."

"; return; } ?>