0

When I was reading the WordPress Codex about outputting the Post and Pages I saw these two Titles at Here

Output a list of all registered post types

and

Output a list of all public custom post types

now can you please let me know
1 - What are Registered posts? Is there any un-registered one?
2 - What are the Public Custom Post Types? is there any Private one?

Thanks

3
  • register_post_type have a parameter public. Controls how the type is visible to authors and readers. If a post type public is true then it is exclude_from_search, publicly_queryable, show_in_nav_menus, and show_ui. read more here. codex.wordpress.org/Function_Reference/register_post_type
    – Robert hue
    Sep 26, 2014 at 15:21
  • Also all post types must be registered (there is no un-registered post type) but a post type can have option to be public or not.
    – Robert hue
    Sep 26, 2014 at 15:23
  • @Roberthue - please add that as an answer!
    – Milo
    Sep 26, 2014 at 15:33

1 Answer 1

0

Adding here.

register_post_type function have a parameter public which controls how the type is visible to authors and readers.

If public parameter of a post type is true then post type will be exclude_from_search, publicly_queryable, show_in_nav_menus, and show_ui. Read more about it in register_post_type function.

Also all post types must be registered to use in WordPress. So there is not such thing as un-registered post type but a registered post type can have option to be public or not based on what value you supply.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.