bp_core_learndash_certificates_enables()
Check if there is any certificated created by the admin and if so then show the certificate tab or else hide the tab
Description
Return
($value) bool
Source
File: bp-integrations/learndash/bp-learndash-functions.php
function bp_core_learndash_certificates_enables() {
$value = false;
$query = array(
'post_type' => 'sfwd-certificates',
);
$query = new \WP_Query( $query );
if ( $query->have_posts() ) {
$value = true;
}
return $value;
}
Changelog
| Version | Description |
|---|---|
| BuddyBoss 1.2.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.