This file contains 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 | |
/* | |
Plugin Name: l3rady's CPT Structure Helper | |
Plugin URI: http://l3rady.com/projects/l3rady-cpt-structure-helper/ | |
Description: | |
Author: Scott Cariss | |
Version: 0.2.1 | |
Author URI: http://l3rady.com/ | |
Text Domain: sccptshelper | |
Domain Path: /languages |
This file contains 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 cmb_opt_groups( $args, $defaults, $field_object, $field_types_object ) { | |
// Only do this for the field we want (vs all select fields) | |
if ( '_cmb_option_field' != $field_types_object->_id() ) { | |
return $args; | |
} | |
$option_array = array( | |
'Group 1' => array( |