dimanche 1 février 2015

Custom post status not working


I'm trying to create two custom post status'. I used the Codex to generate the code and that didn't work. Then I went to http://ift.tt/1z1ZRhT and it didn't work either. It isn't showing up in the dropdown next to "Status" in "Edit Post".


Do you see anything wrong with my code?



// ***** http://ift.tt/1z1ZRhT **** //

function custom_post_status() {

$args = array(
'label' => 'Reserve',
'label_count' => 'Reserve (%s)',
'public' => false,
'show_in_admin_all_list' => true,
'show_in_admin_status_list' => true,
'exclude_from_search' => false,
);
register_post_status( 'Reserve', $args );

}

add_action( 'init', 'custom_post_status', 0 );

function custom_post_status_2() {

$args = array(
'label' => 'Ready to be Scheduled',
'label_count' => 'Ready to be Scheduled (%s)',
'public' => false,
'show_in_admin_all_list' => true,
'show_in_admin_status_list' => true,
'exclude_from_search' => false,
);
register_post_status( 'Ready to be Scheduled', $args );

}

add_action( 'init', 'custom_post_status_2', 0 );


Thank you!





Aucun commentaire:

Enregistrer un commentaire