diff options
author | Karl 'vollmerk' Vollmer <vollmer@ampache.org> | 2007-12-02 00:25:07 +0000 |
---|---|---|
committer | Karl 'vollmerk' Vollmer <vollmer@ampache.org> | 2007-12-02 00:25:07 +0000 |
commit | 6a335845ccd2650e2444080a5faa5dc6151ab993 (patch) | |
tree | 29bb4c54b00e24f13db2fe38adc002492c7d151b /templates/rightbar.inc.php | |
parent | 362610c13217a9ee364f97262c2fc878d97c335a (diff) | |
download | ampache-6a335845ccd2650e2444080a5faa5dc6151ab993.tar.gz ampache-6a335845ccd2650e2444080a5faa5dc6151ab993.tar.bz2 ampache-6a335845ccd2650e2444080a5faa5dc6151ab993.zip |
fixed democratic play ordering along with some misc play isues with it, limited object on rightbar to 100 also started fixing the user registration, which I had forgotten about
Diffstat (limited to 'templates/rightbar.inc.php')
-rw-r--r-- | templates/rightbar.inc.php | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/templates/rightbar.inc.php b/templates/rightbar.inc.php index 85d935c5..bf1322e1 100644 --- a/templates/rightbar.inc.php +++ b/templates/rightbar.inc.php @@ -75,6 +75,13 @@ <?php //FIXME :: this feels kludgy $objects = $GLOBALS['user']->playlist->get_items(); + + // Limit the number of objects we show here + if (count($objects) > 100) { + $truncated = (count($objects) - 100); + $objects = array_slice($objects,0,100); + } + foreach ($objects as $uid=>$object_data) { if ($object_data['1'] == 'radio' || $object_data['1'] == 'song') { $object = new $object_data['1']($object_data['0']); @@ -92,6 +99,11 @@ <?php } if (!count($objects)) { ?> <li class="error"><?php echo _('Not Enough Data'); ?></li> <?php } ?> +<?php if ($truncated) { ?> + <li class="<?php echo flip_class(); ?>"> + <?php echo $truncated . ' ' . _('More'); ?>... + </li> +<?php } ?> </ul> |