indiantown
Technical User
<?
//Now grab a section of that
$db->open(
"SELECT songlist.title, songlist.id, songlist.count_played, songlist.filename, songlist.artist, songlist.album, songlist.duration FROM songlist, category, categorylist WHERE category.name = 'Top 10' AND songlist.id = categorylist.songID AND category.id = categorylist.categoryID ORDER BY songlist.count_played DESC, songlist.date_played ASC LIMIT 20");
$first = $start+1;
$last = min($cnt,$start+$limit);
$rc = $start;
function PutSongRow($song)
{
global $rc, $start, $darkrow, $lightrow;
$rc++;
$bgcolor = $darkrow;
if(($rc % 2)==0) $bgcolor = $lightrow;
PrepareSong($song);
?>
<font size="2" color="#003366"><small><? echo "$rc"; ?>.
<a href="javascript:songinfo(<? echo $song["songid"]; ?>)"><? echo $song["artist"]; ?></a></small></font> <br>
<font size="2" color="#003366"><small> <? echo $song["title"]; ?></small></font><br>
<?
}//PutSongRow
/* ## ===================================================================== ## */
?>
<table width="100%" bgcolor="<? echo $lightrow; ?>" border="0" cellspacing="0" cellpadding="5">
<tr bgcolor="<? echo $darkrow; ?>"><td height="14" colspan="2" class="rightbanner" nowrap> Top 10 Countdown</td></tr>
<tr><td nowrap>
<?
while($song = $db->row())
PutSongRow($song);
?>
</table>
Hi All,
The above script is what I am using to display songs. At present all 20 show alphabetically in the format
1
2
3
4
/
/
/
/
/
/
20
But I want to display in the format
1 11
2 12
/
/
/
10 20
Please help me I am not able to make it happen.
TIA.
//Now grab a section of that
$db->open(
"SELECT songlist.title, songlist.id, songlist.count_played, songlist.filename, songlist.artist, songlist.album, songlist.duration FROM songlist, category, categorylist WHERE category.name = 'Top 10' AND songlist.id = categorylist.songID AND category.id = categorylist.categoryID ORDER BY songlist.count_played DESC, songlist.date_played ASC LIMIT 20");
$first = $start+1;
$last = min($cnt,$start+$limit);
$rc = $start;
function PutSongRow($song)
{
global $rc, $start, $darkrow, $lightrow;
$rc++;
$bgcolor = $darkrow;
if(($rc % 2)==0) $bgcolor = $lightrow;
PrepareSong($song);
?>
<font size="2" color="#003366"><small><? echo "$rc"; ?>.
<a href="javascript:songinfo(<? echo $song["songid"]; ?>)"><? echo $song["artist"]; ?></a></small></font> <br>
<font size="2" color="#003366"><small> <? echo $song["title"]; ?></small></font><br>
<?
}//PutSongRow
/* ## ===================================================================== ## */
?>
<table width="100%" bgcolor="<? echo $lightrow; ?>" border="0" cellspacing="0" cellpadding="5">
<tr bgcolor="<? echo $darkrow; ?>"><td height="14" colspan="2" class="rightbanner" nowrap> Top 10 Countdown</td></tr>
<tr><td nowrap>
<?
while($song = $db->row())
PutSongRow($song);
?>
</table>
Hi All,
The above script is what I am using to display songs. At present all 20 show alphabetically in the format
1
2
3
4
/
/
/
/
/
/
20
But I want to display in the format
1 11
2 12
/
/
/
10 20
Please help me I am not able to make it happen.
TIA.