blog_id, $comment_post_ID, ); $addcomment = implode(", ", $thisnewcomment); $LatestCommentsList = $current_user->LatestComments; if (!$LatestCommentsList){ $LatestCommentsList = array(); }else{ $array = explode(", ", $current_user->LatestComments); } if (!in_array($addcomment, $LatestCommentsList)) { array_push($LatestCommentsList, $addcomment); if (count($LatestCommentsList) > 9){ unset($LatestCommentsList[0]); array_unshift($LatestCommentsList, array_shift($LatestCommentsList)); if (!isset($LatestCommentsList[0])) { $LatestCommentsList = array(); } } } update_usermeta($current_user->ID, 'LatestComments', $LatestCommentsList); } add_action('comment_post', 'track_user_comment_posting'); function xiando_tracked_comments_overview(){ global $current_site; global $current_blog; global $current_user; global $wpdb; global $wpmuBaseTablePrefix; echo '
You have not written any comments on this blogservice after this particular comment-related plugin was installed, so sorry. Write a comment at someones blog and revisit this page to view your own comments being tracked.
'; } foreach (array_reverse($current_user->LatestComments) as $key => $tmp_comment_post_array){ $thiscomment = explode(", ", $tmp_comment_post_array); $commentedatblogdetails = get_blog_details( $thiscomment[0] ); // Blog Post Content Assimilation $blogCommentsTable = $wpmuBaseTablePrefix.$thiscomment[0]."_comments"; $mycomments = array(); $mycomments = $wpdb->get_results("SELECT comment_author, comment_ID, comment_content, comment_date_gmt, comment_post_ID, user_id FROM $blogCommentsTable WHERE comment_post_ID = '$thiscomment[1]' AND comment_date_gmt >= DATE_SUB(CURRENT_DATE(), INTERVAL 20 DAY) ORDER BY comment_date_gmt DESC LIMIT 0,3", ARRAY_A); // Blog Post Content Assimilation. Resistance = futile. $blogPostsTable = $wpmuBaseTablePrefix.$thiscomment[0]."_posts"; $thispost = $wpdb->get_results("SELECT post_title, post_content, post_password, comment_count, post_author, guid FROM $blogPostsTable WHERE id = '$thiscomment[1]' AND post_status = 'publish' AND post_type = 'post' ORDER BY id DESC LIMIT 0,1"); $wTMP = ''; if($thispost){ $wTMP .= "\n\t" . $thispost[0]->comment_count . " totalt.
"; $wTMP .= "\n\t