SQL is only getting 1 row
<p>I'm making a like system in php and I have a code to get all the usernames of the people who liked the post using the post id and if they haven't liked the post it will show a button that say like post and it if they haven't it will show a button that says unlike post and if there's no like it will say "No one has liked the post be the first". But when I add it in, it only get 1 user id even though multiple people have liked the post, how do I fixed this, here is my code: </p>

<pre><code>$fancy = $db-&gt;fetch("SELECT * FROM " . $prefix . "_fancy WHERE post_id = '" . $post_row['id'] . "' ORDER BY id");

if ($fancy) {
    $name = $user-&gt;name($fancy['account_id']);
    if ($account['id'] !== $fancy['account_id']) {
        $fancytext = '&lt;div&gt;'.$name.' Like this post.&lt;!-- BEGIN logged_in --&gt; &lt;a href="./?area=forum&amp;amp;s=topic&amp;amp;t='.$topic_id.'&amp;amp;f='.$pid.'"&gt;&lt;img src="./template/default/images/like.png" alt="" border="0"/&gt;&lt;/a&gt;&lt;!-- END logged_in --&gt;
&lt;/div&gt;';
    } else {
        $fancytext = '&lt;div&gt;'.$name.' Like this post.&lt;!-- BEGIN logged_in --&gt; &lt;a href="./?area=forum&amp;amp;s=topic&amp;amp;t='.$topic_id.'&amp;amp;unf='.$pid.'"&gt;&lt;img src="./template/default/images/unlike.png" alt="" border="0"/&gt;&lt;/a&gt;&lt;!-- END logged_in --&gt;
&lt;/div&gt;';
    }
} else {
    $fancytext = '&lt;div&gt;&lt;i&gt;No one has liked this post, be the first!&lt;/i&gt; &lt;!-- BEGIN logged_in --&gt;&lt;a href="./?area=forum&amp;amp;s=topic&amp;amp;t='.$topic_id.'&amp;amp;f='.$pid.'"&gt;&lt;img src="./template/default/images/like.png" alt="" border="0"/&gt;&lt;/a&gt;&lt;!-- END logged_in --&gt;
&lt;/div&gt;';
}
</code></pre>
