WordPress.org

Forums

Related Posts for WordPress
Undefined index: MRP_related_posts (2 posts)

  1. sem101
    Member
    Posted 1 year ago #

    PHP Notice:

    wp-content/plugins/microkids-related-posts/microkids-related-posts.php on line 282

    Warning: Cannot modify header information - headers already sent by (output started at:

    wp-content/plugins/microkids-related-posts/microkids-related-posts.php:282

    AND

    wp-content/plugins/microkids-related-posts/microkids-related-posts.php:282

    https://wordpress.org/plugins/microkids-related-posts/

  2. Tada Burke
    Member
    Posted 1 year ago #

    @sem101, when receiving, "Undefined Index," notices from PHP, usually a key is not set. You check if it's set with:

    isset()

    Example:

    MRP_save_relationships( $post_id, isset( $_POST['MRP_related_posts'] ) );

    The developer may wish to add a ternary operator as well. Good luck.

Topic Closed

This topic has been closed to new replies.

About this Plugin

  • Related Posts for WordPress
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic