Tagged: 

Viewing 7 reply threads
  • Author
    Posts
    • #345
      kattagami
      Member

      Hello,

      I created a plugin which create two Custom Post Type.
      When I activate my plugin, I’ve got this Notice :


      Notice: Undefined index: days in /www/wordpress/wp-content/plugins/piklist/includes/class-piklist-cpt.php on line 122

      With one CPT, no problem. With three CPT, I have two Notices, the same as above but for two of the three CPT.

      This is the code of my two files in /my_plugin/parts/meta-boxes/


      <?php
      /*
      Title: Presentation descriptions
      Post Type: presentations
      */


      <?php
      /*
      Title: Day descriptions
      Post Type: days
      */

    • #348
      Steve
      Keymaster

      @kattagami– Can you post your code for REGISTERING the CPT’s?

      Please use a service like Pastie or Gist

    • #349
      kattagami
      Member

      This is my code. These pieces of code are used in two different Classes. I just paste the CPT registration function.

      Gist code

    • #350
      Steve
      Keymaster

      @kattagami– We really need to see more code so we can reproduce.

    • #351
      kattagami
      Member

      Ok I will come back with more code. I will try to reproduce the problem with a simplified version of my plugin. May be tomorrow otherwise in a week.

      Thank you

    • #352
      kattagami
      Member

      This is a very simplified version of my plugin.

      My environnement:
      WordPress 3.4.2
      Piklist 0.6.6
      Empty Data base
      No other plugin activated apart from Piklist plugin.

      This is a simple plugin to use with 2010 theme of WP for example.

      This plugin just creates two CPTs (CPT1 and CPT2) and two Pages.

      When you activate this plugin, you must see this Notice:


      Notice: Undefined index: cpt2 in xxx/www/wordpress/wp-content/plugins/piklist/includes/class-piklist-cpt.php on line 122

      I hope this code could help you.

    • #393
      Steve
      Keymaster

      @kattagami– Will be fixed in v0.6.7

    • #396
      Steve
      Keymaster

      v0.6.7 has been released

Viewing 7 reply threads
  • You must be logged in to reply to this topic.