There are a couple suggestions I would make for you to improve your code.
1) Use mysql_fetch_array() instead of mysql_fetch_row(). This way you don't need a call to list, but you can output your values like the following:
If you use ($row=mysql_fetch_array($results)) then your field names will be the index of $row.
echo ("$row['id'], $row['img'], $row['$comment'] .... ");
2) It looks like you want to have a maximum of 10 results per page. You can use the LIMIT SQL clause to accomplish this, and this will also help you with multiple pages.
Use
$results = mysql_query("select * from table order by rank limit 10, $offset", $db_connect);
This will limit you to 10 records per page. $offset should be the starting record, or 10 * page number. If you are on the 3rd page, the limit part would be "limit 10, 30" so it would get 10 records starting with the 30th record.
3) I'm not sure exactly how you want your columns formatted, but since you are sorting by rank, it looks like you want the top 5 starting in the left column and the lower 5 in the right column. What happens if you have less than 10 records on a page? Do you still want it to fill the left column first, or to split the records evenly between the two columns?
Also, do you want it to have a layout like follows:
1 2
3 4
5 6
...
instead of
1 5
2 6
3 7
4 8
5 9
(which is will be now)
If so, your code will get even easier. Let me know and I can show you either way...
4) In your code
// second column
for ($i=i+1;$i<=$col;$i++)
{
It looks like you are missing a $ in front of the second time you reference $i.
Hope this helps.
Dave