function bbpvotes_get_votes_log_ajax() { if (!isset($_POST['post_id'])) { return false; } echo bbpvotes_get_post_votes_log($_POST['post_id']); die; }
function post_content_append_votes_log($content = '', $post_id = 0) { if (!$this->options['embed_votes_log']) { return $content; } if (is_admin() || is_feed()) { return $content; } // Bail if in admin or feed if (!in_array(get_post_type($post_id), $this->supported_post_types)) { return $content; } // Validate the ID //$topic_id = bbp_get_topic_id( $topic_id ); return apply_filters('bbpvotes_post_append_votes', $content . bbpvotes_get_post_votes_log($post_id), $content, $post_id); }