The piklist_post_types filter lets you register your custom Post Types through Piklist. This gives you access to additional functionality that Piklist offers.
To register a Post Type with Piklist:
- Create a function with your Post Type parameters.
- Hook it to the piklist_post_types() filter.
The examples above use the Piklist function to automagically set the proper singular/plural values for your Post Type, like this
'labels' => piklist('post_type_labels', 'Demo'). However, if you like, you can also manually define individual labels the WordPress way as defined in the WordPress Codex.
This filter supports every parameter that
register_post_type() supports. Additionally, you may use the following Piklist specific parameters.
Add custom classes to the body attribute of any page that displays this post type. In the admin only.
Change the titles of the columns on the list posts screen.
Easily hide meta boxes per post type. Even if the Post Type “supports” the metabox, you can still hide it.
Hide the post row actions that show up when you hover over a post in the list posts screen (e.g. edit, quick edit, trash, preview)
Hide the screen options tab on the post edit screens.
Register custom post statuses to use with this Post Type. A few important notes:
1. You must define ALL the statuses for your Post Type.
2. Statuses are universal, meaning any status you register cannot have the same key as an existing status. If it does, the label you define will change the other status as well.
3. You can use any parameter from the register_post_status function.
Change the “Enter title here” text that appears when you create a new Post.
WordPress doesn’t allow a Post Type slug defined as ‘order’. This is not allowed
'slug' => 'order