diff options
author | Karl 'vollmerk' Vollmer <vollmer@ampache.org> | 2007-04-23 18:59:35 +0000 |
---|---|---|
committer | Karl 'vollmerk' Vollmer <vollmer@ampache.org> | 2007-04-23 18:59:35 +0000 |
commit | 0557ea37ad1396c605198d4ed072b77971ec9ad7 (patch) | |
tree | 8381db050b60bfe98b535431a5411720c5c855ac /templates/show_now_playing.inc.php | |
parent | 45250f50194cac99fde9569d8e8fd54ad89db179 (diff) | |
download | ampache-0557ea37ad1396c605198d4ed072b77971ec9ad7.tar.gz ampache-0557ea37ad1396c605198d4ed072b77971ec9ad7.tar.bz2 ampache-0557ea37ad1396c605198d4ed072b77971ec9ad7.zip |
fixed now playing
Diffstat (limited to 'templates/show_now_playing.inc.php')
-rw-r--r-- | templates/show_now_playing.inc.php | 51 |
1 files changed, 51 insertions, 0 deletions
diff --git a/templates/show_now_playing.inc.php b/templates/show_now_playing.inc.php new file mode 100644 index 00000000..0bdba057 --- /dev/null +++ b/templates/show_now_playing.inc.php @@ -0,0 +1,51 @@ +<?php +/* + +Copyright (c) 2001 - 2007 Ampache.org +All rights reserved. + +This program is free software; you can redistribute it and/or +modify it under the terms of the GNU General Public License +as published by the Free Software Foundation; either version 2 +of the License, or (at your option) any later version. + +This program is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU General Public License for more details. + +You should have received a copy of the GNU General Public License +along with this program; if not, write to the Free Software +Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. + +*/ + +/** + * This is the now playing container, it holds the master div for now playing + * and loops through what's current playing as passed and includes + * the now_playing_row's This will display regardless, but potentially + * goes all ajaxie if you've got javascript on + */ + +if (count($results)) { +?> +<?php show_box_top(_('Now Playing')); ?> +<table class="tabledata"> +<?php +foreach ($results as $item) { + $song = $item['song']; + $np_user = $item['user']; + + /* If we've gotten a non-song object just skip this row */ + if (!is_object($song)) { continue; } + if (!$np_user->fullname) { $np_user->fullname = "Ampache User"; } + + echo '<tr class="np_row">'; + require Config::get('prefix') . '/templates/show_now_playing_row.inc.php'; + echo '</tr>'; + +} // end foreach +?> +</table> +<?php show_box_bottom(); ?> +<?php } // end if count results ?> |