<?xml version="1.0" encoding="UTF-8"?>
<code>
  <code>&lt;ul&gt;
&lt;?php $result = $wpdb-&gt;get_results(&quot;SELECT comment_count,ID,post_title FROM $wpdb-&gt;posts ORDER BY comment_count DESC LIMIT 0 , 5&quot;);
foreach ($result as $post) {
setup_postdata($post);
$postid = $post-&gt;ID;
$title = $post-&gt;post_title;
$commentcount = $post-&gt;comment_count;
if ($commentcount != 0) { ?&gt;
&lt;li&gt;&lt;a href=&quot;&lt;?php echo get_permalink($postid); ?&gt;&quot; title=&quot;&lt;?php echo $title ?&gt;&quot;&gt;
&lt;?php echo $title ?&gt;&lt;/a&gt; {&lt;?php echo $commentcount ?&gt;}&lt;/li&gt;
&lt;?php } } ?&gt;
&lt;/ul&gt;</code>
  <created-at type="datetime">2009-08-22T15:30:43Z</created-at>
  <description></description>
  <id type="integer">196</id>
  <language-id type="integer">35</language-id>
  <privated type="boolean">false</privated>
  <title>wordpress popular posts</title>
  <updated-at type="datetime">2009-08-22T15:30:43Z</updated-at>
  <user-id type="integer">7</user-id>
</code>
