Created
December 23, 2014 15:50
-
-
Save wpmark/6e8c2058eec452ce6195 to your computer and use it in GitHub Desktop.
Add new Taxonomies in WP Broadbean
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 wpmark_add_wpbb_taxonmies() | |
* adds new taxonomies for jobs | |
* @param (array) $tax is the current array of taxonomies to add | |
* @return (array) $tax is the new array of modified taxonomies to add | |
*/ | |
function wpmark_add_wpbb_taxonmies( $tax ) { | |
$tax[ 'country' ] = array( | |
'taxonomy_name' => 'wpbb_country', | |
'broadbean_field' => 'job_country', | |
'plural' => 'Countries', | |
'singular' => 'Country', | |
'slug' => 'job-country', | |
'menu_label' => 'Countries', | |
'hierarchical' => true, | |
'show_admin_column' => true | |
) | |
return $tax; | |
} | |
add_filter( 'wpbb_registered_taxonomies', 'wpmark_add_wpbb_taxonmies' ); | |
?> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment