WordPress.org

Support

Support » Plugins and Hacks » Related Links » [Resolved] [Plugin: Related Links] Ajax call to load_links_list() has an error

[Resolved] [Plugin: Related Links] Ajax call to load_links_list() has an error

  • 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()
    	};

    http://wordpress.org/extend/plugins/related-links/

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