Created
October 13, 2016 07:43
-
-
Save svenl77/4421a5ce67f62707debdf7f17254f4d4 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 we use to add a extra class to all BuddyForms related metaboxes. | |
*/ | |
function buddyforms_metabox_class($classes) { | |
$classes[] = 'buddyforms-metabox'; | |
return $classes; | |
} | |
/** | |
* Metabox show if form type is posts | |
*/ | |
function buddyforms_metabox_show_if_form_type_post($classes) { | |
$classes[] = 'buddyforms-metabox-show-if-form-type-post'; | |
return $classes; | |
} | |
/** | |
* Metabox show if form type is registration | |
*/ | |
function buddyforms_metabox_show_if_form_type_registration($classes) { | |
$classes[] = 'buddyforms-metabox-show-if-form-type-registration'; | |
return $classes; | |
} | |
/** | |
* Metabox show if attached page is selected | |
*/ | |
function buddyforms_metabox_show_if_attached_page($classes) { | |
$classes[] = 'buddyforms-metabox-show-if-attached-page'; | |
return $classes; | |
} | |
/** | |
* Metabox show if form post type is not none ( bf_submissions ) | |
*/ | |
function buddyforms_metabox_show_if_post_type_none($classes) { | |
$classes[] = 'buddyforms-metabox-show-if-post-type-none'; | |
return $classes; | |
} | |
/** | |
* Metabox show if form post type is not none ( bf_submissions ) | |
*/ | |
function buddyforms_metabox_hide_if_form_type_register($classes) { | |
$classes[] = 'buddyforms-metabox-hide-if-form-type-register'; | |
return $classes; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment