{"id":643363,"date":"2010-03-26T17:24:38","date_gmt":"2010-03-26T17:24:38","guid":{"rendered":"http:\/\/www.xptt.com\/solution-can-not-hide-the-lords-latest-comments-bo.html"},"modified":"2020-02-20T06:04:56","modified_gmt":"2020-02-20T09:04:56","slug":"solution-can-not-hide-the-lords-latest-comments-bo","status":"publish","type":"post","link":"https:\/\/xptt.com\/643363.html","title":{"rendered":"\u89e3\u51b3\u65e0\u6cd5\u9690\u85cf\u535a\u4e3b\u7684\u6700\u65b0\u8bc4\u8bba"},"content":{"rendered":"<p> \u4e3a\u4e86\u8c03\u6574\u8bc4\u8bba\u7684\u4e8b\u60c5\uff0c\u53c8\u6298\u817e\u8d77\u6765\u4e86\uff0c\u4ee5\u524d\u90a3\u6bb5\u8bc4\u8bba\u8c03\u7528\u4ee3\u7801\u5df2\u7ecf\u5f88\u6ee1\u610f\u4e86\uff0c\u4f46\u662f\u6700\u8fd1\u60f3\u6362\u4e2a\u82b1\u6837\uff0c\u6240\u4ee5\u518d\u6b21\u6298\u817e\uff0c\u5e73\u65f6\u6298\u817e\u8d77\u6765\u4e5f\u5c31\u52a0\u4e0b\u4ee3\u7801\uff0c\u6539\u4e0b\u4ee3\u7801\uff0c\u8fd9\u6b21\u8fd8\u771f\u9047\u5230\u4e00\u4e2a\u5947\u602a\u7684\u4e8b\u60c5\uff0c\u5e0c\u671b\u77e5\u9053\u7684\u7ae5\u978b\u7559\u8a00\u544a\u4e4b\u5176\u539f\u7406\uff0c\u867d\u7136\u89e3\u51b3\u4e86\uff0c\u4f46\u8fd8\u662f\u7591\u70b9\u591a\u591a\uff01\u5728\u8fd8\u6ca1\u89e3\u51b3\u4e4b\u524d\uff0cgoogle\u4e86\u4e00\u4e0b\uff0c\u53c2\u7167ZWWoOoOo\u7684<a href=\"http:\/\/zww.me\/archives\/24736\" target=\"_blank\" rel=\"noopener noreferrer\">\u5e26\u5934\u50cf\u663e\u793a\u7684\u6700\u65b0\u8bc4\u8bba\u4ee3\u7801 - \u5b8c\u5584\u7bc7<\/a> \u4e0d\u884c\uff0c\u597d\u6362\u4e2a\u770b\u770b\uff0c\u7ee7\u7eedgoogle\uff0c\u4e07\u6208\u7684Wordpress \u9690\u85cf\u535a\u4e3b\u7684\u6700\u65b0\u7559\u8a00 \u53c8\u4e0d\u884c\uff0c\u597d\u4e86\uff0c\u4e0d\u7ee7\u7eed\u4e86\uff0c\u4ed4\u7ec6\u770b\u4e0b\u4ee3\u7801\uff0c\u90fd\u5dee\u4e0d\u591a\uff0c\u53ea\u662f\u7f8e\u89c2\u95ee\u9898\uff0c\u6211\u611f\u89c9\u8fd8\u662f\u5f88\u559c\u6b22zwwooooo\u73b0\u5728\u7684\u4fa7\u8fb9\u6700\u65b0\u8bc4\u8bba\uff0c\u524d\u9762\u662f\u5934\u50cf\uff0c\u53f3\u4e0a\u9762\u662f\u5185\u5bb9\uff0c\u53f3\u4e0b\u9762\u662f\u4f5c\u8005\uff0c\u770b\u8d77\u6765\u5f88\u4e0d\u9519\uff0c\u5c31\u662f\u4e0d\u77e5\u9053\u4ed6\u80af\u5171\u4eab\u5177\u4f53\u6837\u5f0f\u4e48\uff1f\u5475\u5475\uff0c\u8bdd\u64a4\u56de\u6765\uff0c\u65e0\u975e\u6700\u91cd\u8981\u7684\u5c31\u662f\u90a3\u53e5\uff1acomment_author != '\u90d1 \u6c38' \uff0c\u4f46\u662f\u5927\u5bb6\u4ed4\u7ec6\u89c2\u5bdf\u4e00\u4e0b\u4e0b\u9762\u7684\u4e24\u6bb5\u4e2a\u4ee3\u7801\uff0ccomment_author != 'zhengyong' \u548c\u524d\u9762\u8bf4\u7684\u6709\u4f55\u533a\u522b\uff1f\u5c31\u56e0\u4e3a\u8fd9\u4e2a\u95ee\u9898\uff0c\u521a\u5f00\u59cb\u56e0\u4e3a\u4e0d\u77e5\u9053\uff0c\u4e00\u76f4\u4ee5\u4e3a\u586bzhengyong\u5c31\u53ef\u4ee5\u4e86\uff0c\u56e0\u4e3a\u4e0a\u9762\u90a3\u6bb5\u4ee3\u7801\u662f\u53ef\u4ee5\u7684\uff0c\u5927\u5bb6\u53ef\u4ee5\u60f3\u8c61\u4e00\u4e0b\uff0c\u8fd9\u4e00\u6298\u817e\u6211\u8bd5\u4e86\u591a\u5c11\u4e2a\u4ee3\u7801\uff0c\u751a\u81f3\u5728\u60f3\u662f\u5426\u56e0\u4e3a\u4e00\u4e2a\u9875\u9762\u8c03\u7528\u4e86\u4e24\u6b21\uff0c\u6240\u4ee5\u624d\u51fa\u73b0\u95ee\u9898\u7684\uff1f\u4f46\u5c31\u5728\u521a\u624d\u6211\u53bb\u4e07\u6208\u7684Wordpress \u9690\u85cf\u535a\u4e3b\u7684\u6700\u65b0\u7559\u8a00\u770b\u5230\u4ed6\u7684\u4f8b\u5b50\u586b\u7684\u662f\u4e2d\u6587\u540d\u5b57\uff0c\u4e8e\u662f\u6211\u5c31\u597d\u5947\u7684\u586b\u4e2d\u6587\u540d\u5b57-\u90d1\u6c38\uff0c\u7ed3\u679c\u8fd8\u662f\u4e0d\u884c\uff0c\u8fd9\u5c31\u602a\u4e86\uff0c\u7a81\u7136\u9a6c\u4e0a\u60f3\u5230\u4e07\u6208\u7684\u540d\u5b57\u5e94\u8be5\u4e0d\u4f1a\u5728\u540e\u53f0\u586b\u5199\u59d3\u4e07\u540d\u6208\u5427\uff1f\u6211\u731c\u8fd9\u4e5f\u4e0d\u662f\u4ed6\u771f\u540d\u5427\uff01\u8bf4\u5230\u540d\u5b57\uff0c\u518d\u8bf4\u8bf4Zwwooooo\uff0c\u6211\u731c\u4ed6\u662f\u7b2c4\u4e2a\u8d77zwwo\u8fd9\u4e2a\u540d\u5b57\u7684\u4eba\uff0c\u56e0\u4e3a\u524d\u4e09\u4e2a\u90fd\u88ab\u62a2\u4e86\uff0c\u8d85\u5178\u578b\u7684\u62a2\u6ce8\u540d\u5b57\u554a\uff01\u8bdd\u64a4\u56de\u6765\uff0c\u4e8e\u662f\u6211\u5c31\u5728\u6211\u540d\u5b57\u4e2d\u95f4\u52a0\u4e2a\u7a7a\u683c\uff0c\u8fd9\u4ee3\u7801\u8fd8\u771f\u725b\u4e86\uff0c\u771f\u80fd\u8bc6\u522b\u59d3\u540d\u51fa\u6765\uff0c\u5c31\u8fd9\u6837\u89e3\u51b3\u4e86\uff0c\u5927\u5bb6\u8981\u662f\u6709\u9047\u5230\u540c\u7c7b\u4e8b\u60c5\uff0c\u591a\u8bd5\u8bd5\u81ea\u5df1\u7684\u7528\u6237\u540d\u5427\u3002<\/p>\n<blockquote>\n<p>&lt;h2&gt;\u8e0a\u8dc3\u53d1\u8a00\u6392\u884c&lt;\/h2&gt;<br \/> &lt;ul class=\"ffox_most_active\"&gt;<br \/> &lt;?php<br \/> $counts = $wpdb-&gt;get_results(\"SELECT COUNT(comment_author) AS cnt, comment_author, comment_author_url, comment_author_email FROM (SELECT * FROM $wpdb-&gt;comments LEFT OUTER JOIN $wpdb-&gt;posts ON ($wpdb-&gt;posts.ID=$wpdb-&gt;comments.comment_post_ID) WHERE comment_date &gt; date_sub( NOW(), INTERVAL 1 MONTH ) AND user_id='0' AND comment_author != 'zhengyong' AND post_password='' AND comment_approved='1' AND comment_type='') AS tempcmt GROUP BY comment_author ORDER BY cnt DESC LIMIT 12\");<br \/> foreach ($counts as $count) {<br \/> $c_url = $count-&gt;comment_author_url;<br \/> if ($c_url == '') $c_url = '<a href=\"http:\/\/www.xptt.com\/';\">http:\/\/www.xptt.com\/';<\/a><br \/> $mostactive .= '&lt;zhengyong class=\"mostactive\"&gt;' . '&lt;a href=\"'. $c_url . '\" title=\"' . $count-&gt;comment_author . ' ('. $count-&gt;cnt\u00a0 . '\u8bc4\u8bba)\"&gt;' .get_avatar($count-&gt;comment_author_email,40).'&lt;\/a&gt;&lt;\/zhengyong&gt;';<br \/> }<br \/> echo $mostactive;<br \/> ?&gt;<br \/> &lt;\/ul&gt;<\/p>\n<\/blockquote>\n<p>\u4ee5\u4e0a\u4ee3\u7801\u662f\u6709\u6548\u679c\u7684\u3002<\/p>\n<blockquote>\n<p>&lt;div class=\"widget\"&gt;<br \/> &lt;h3&gt;\u6700\u65b0\u8bc4\u8bba&lt;\/h3&gt;<br \/> &lt;ul&gt;<br \/> &lt;?php<br \/> global $wpdb;<br \/> $sql = \"SELECT DISTINCT ID, post_title, post_password, comment_ID, comment_post_ID, comment_author, comment_date_gmt, comment_approved,comment_author_email, comment_type,comment_author_url, SUBSTRING(comment_content,1,12) AS com_excerpt FROM $wpdb-&gt;comments LEFT OUTER JOIN $wpdb-&gt;posts ON ($wpdb-&gt;comments.comment_post_ID = $wpdb-&gt;posts.ID) WHERE comment_approved = '1' AND comment_type = '' AND comment_author != '\u90d1 \u6c38' AND post_password = '' ORDER BY comment_date_gmt DESC LIMIT 10\";<br \/> $comments = $wpdb-&gt;get_results($sql);<br \/> $output = $pre_HTML;<br \/> foreach ($comments as $comment) {<br \/> $output .= \"\\n&lt;li&gt;\".get_avatar(get_comment_author_email('comment_author_email'), 18). \" &lt;a href=\\\"\" . get_permalink($comment-&gt;ID) . \"#comment-\" . $comment-&gt;comment_ID . \"\\\" title=\\\"\" . $comment-&gt;post_title . \" \u4e0a\u7684\u8bc4\u8bba\\\"&gt;\". strip_tags($comment-&gt;comment_author) .\"\uff1a \". strip_tags($comment-&gt;com_excerpt) .\"&lt;\/a&gt;&lt;\/li&gt;\";<br \/> }<br \/> $output .= $post_HTML;<br \/> $output = convert_smilies($output);<br \/> echo $output;<br \/> ?&gt;<\/p>\n<\/blockquote>\n<p>\u8fd9\u4e2a\u4ee3\u7801\u4e5f\u6709\u6548\u679c\uff01<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u4e3a\u4e86\u8c03\u6574\u8bc4\u8bba\u7684\u4e8b\u60c5\uff0c\u53c8\u6298\u817e\u8d77\u6765\u4e86\uff0c\u4ee5\u524d\u90a3\u6bb5\u8bc4\u8bba\u8c03\u7528\u4ee3\u7801\u5df2\u7ecf\u5f88\u6ee1\u610f\u4e86\uff0c\u4f46\u662f\u6700\u8fd1\u60f3\u6362\u4e2a\u82b1\u6837\uff0c\u6240\u4ee5\u518d\u6b21\u6298\u817e\uff0c\u5e73\u65f6\u6298\u817e [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[3],"tags":[411,1735,186,410],"views":13793,"_links":{"self":[{"href":"https:\/\/xptt.com\/wp-json\/wp\/v2\/posts\/643363"}],"collection":[{"href":"https:\/\/xptt.com\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/xptt.com\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/xptt.com\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/xptt.com\/wp-json\/wp\/v2\/comments?post=643363"}],"version-history":[{"count":0,"href":"https:\/\/xptt.com\/wp-json\/wp\/v2\/posts\/643363\/revisions"}],"wp:attachment":[{"href":"https:\/\/xptt.com\/wp-json\/wp\/v2\/media?parent=643363"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/xptt.com\/wp-json\/wp\/v2\/categories?post=643363"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/xptt.com\/wp-json\/wp\/v2\/tags?post=643363"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}