[Plugin: Developer's Custom Fields] Query Custom Post Type
-
Hi there, thanks for the great plugin first of all!
I’m trying to pull in a list of posts for a custom post type and I don’t get anything in my select field. Here’s my code:
function register_user_fields() { slt_cf_register_box( array( 'type' => 'user', 'title' => 'Member Profile Page', 'id' => 'profile-page-options', 'context' => 'normal', 'priority' => 'high', 'fields' => array( array( 'name' => 'profile-page', 'label' => 'Profile Page', 'type' => 'select', 'scope' => array( 'administrator', 'editor' ), 'capabilities' => array( 'edit_posts' ) ) ), 'options_type' => 'posts', 'options_query' => array( 'posts_per_page' => -1, 'post_type' => 'member' ) )); } add_action('init','register_user_fields');
I’ve got a bunch of members added so there are posts there. Am I doing something wrong?
Thanks,
Jonahhttps://www.ads-software.com/extend/plugins/developers-custom-fields/
Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
- The topic ‘[Plugin: Developer's Custom Fields] Query Custom Post Type’ is closed to new replies.