Viewing 3 reply threads
  • Author
    Posts
    • #5588
      sajonara
      Member

      When I create a new custom post type I use a $labels array to summarize all that can be put in the 'labels' post type array, like so:

      $post_types['ng_game'] = array(
      'labels' => $labels,
      'title' => __('Spiele'),
      'public' => true,
      'publicly_queryable' => true,
      'menu_position' => 5,
      'show_ui' => true,
      'show_in_menu' => true,
      'show_in_nav_menus' => true,
      'query_var' => true,
      'capability_type' => 'page',
      ...
      );

      But if add the menu_icon to the $labels array it is not interpreted, I have to add it somewhere between the above shown code.

      This is just a remark as I found it a bit odd that menu_name could be added to the $labels array but menu_icon cannot.

      Kind regards

    • #5591
      Steve
      Keymaster

      @sajonara– These parameters you are mentioning are standard WordPress functions. Labels are words that appear in the admin. The menu_icon is the url to the icon to be used for this menu. It doesn’t make sense for menu_icon to be in the labels array.

      To see everything that you can include, please refer to the WordPress codex for the register_post_type function.

    • #5592
      sajonara
      Member

      @Steve Thx for the clarification. When working with Piklist one can easily forget which part is generic and which genuine but then you Piklist guys cannot change WordPress’ mistakes.

      Because I strongly believe that in this case WordPress’ nomenclature makes no sense. I first thought both terms belong together, because of their prefix, but obviously they are for different parts of the workflow.

    • #5596
      Steve
      Keymaster

      @sajonara– Piklist is so seamlessly integrated with WordPress, that I guess that’s one issue we never realized…sometimes you don’t know which parts are WordPress, and which are Piklist! 😉

      Closing this ticket.

Viewing 3 reply threads
  • The topic ‘menu_icon not interpreted as label’ is closed to new replies.