• Resolved robert_k

    (@robert_k)


    When using the related links plugin I noticed that with WP_DEBUG on, I kept getting an error warning me that line 236 of “class-related-links-box.php” was attempting to access an attribute of a non-object. The fix is simple: you have to send the Post ID with the ajax call, because the ajax call won’t automagically know what the ID is.

    My patch:

    class-related-links-box.php, line 236:
    $meta = get_post_meta(intval($_POST['post_id']), '_related_links', true);

    script.js, line 118-121:

    var data = {
    		action: "load_links_list",
    		post_id: jQuery('#post_ID').val()
    	};

    https://www.ads-software.com/extend/plugins/related-links/

  • The topic ‘[Plugin: Related Links] Ajax call to load_links_list() has an error’ is closed to new replies.