• Hi Hiroaki,

    I’m developing and the plugin is throwing this error when I’m in the admin panel.

    Notice: Undefined variable: post in C:\wwwroot\anandala\wp-content\plugins\custom-field-template\custom-field-template.php on line 538

    A hack sort of fix is to add this before line 530:

    if ( isset( $post ) ) {
    $post_type = $post->post_type;
    }
    else {
    $post_type = ”;
    }

    Hoping it’s easy for you to make the plugin WP_DEBUG-compatible.

    Thank you!

    https://www.ads-software.com/extend/plugins/custom-field-template/

Viewing 1 replies (of 1 total)
  • Thread Starter Nabha Cosley

    (@nabha)

    Oh, and of course $post->post_type==’page’ on line 530 has to change to $post_type==’page’, using the above code.

    I also forgot to add my thanks to you for developing the plugin, and spending so much time with it. Among other things, it’s a real help in speeding development time for more complex things.

Viewing 1 replies (of 1 total)
  • The topic ‘[Plugin: Custom Field Template] PHP Notice when WP_DEBUG is on’ is closed to new replies.