summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--server/index.ajax.php2
-rw-r--r--templates/show_index.inc.php3
-rw-r--r--templates/show_recently_played.inc.php3
3 files changed, 3 insertions, 5 deletions
diff --git a/server/index.ajax.php b/server/index.ajax.php
index 2573e7d2..3ecae38d 100644
--- a/server/index.ajax.php
+++ b/server/index.ajax.php
@@ -41,9 +41,7 @@ switch ($_REQUEST['action']) {
$data = Song::get_recently_played();
Song::build_cache(array_keys($data));
if (count($data)) {
- show_box_top(_('Recently Played'));
require_once Config::get('prefix') . '/templates/show_recently_played.inc.php';
- show_box_bottom();
}
$results['recently_played'] = ob_get_clean();
break;
diff --git a/templates/show_index.inc.php b/templates/show_index.inc.php
index 81ffd05e..f5b2558d 100644
--- a/templates/show_index.inc.php
+++ b/templates/show_index.inc.php
@@ -42,10 +42,7 @@
<?php
$data = Song::get_recently_played();
Song::build_cache(array_keys($data));
- $link = Config::get('use_rss') ? ' ' . RSS::get_display('recentlyplayed') : '';
- show_box_top(_('Recently Played') . $link);
require_once Config::get('prefix') . '/templates/show_recently_played.inc.php';
- show_box_bottom();
?>
</div>
<!-- Shoutbox Objects, if shoutbox is enabled -->
diff --git a/templates/show_recently_played.inc.php b/templates/show_recently_played.inc.php
index 85b9b423..25ca1396 100644
--- a/templates/show_recently_played.inc.php
+++ b/templates/show_recently_played.inc.php
@@ -21,6 +21,8 @@
/* Define the time places starting at 0 */
$time_unit = array('',_('seconds ago'),_('minutes ago'),_('hours ago'),_('days ago'),_('weeks ago'),_('months ago'),_('years ago'));
+$link = Config::get('use_rss') ? ' ' . RSS::get_display('recentlyplayed') : '';
+show_box_top(_('Recently Played') . $link);
?>
<table class="tabledata" cellpadding="0" cellspacing="0">
<colgroup>
@@ -102,3 +104,4 @@ $time_unit = array('',_('seconds ago'),_('minutes ago'),_('hours ago'),_('days a
<th class="cel_lastplayed"><?php echo _('Last Played'); ?></th>
</tr>
</table>
+<?php show_box_bottom(); ?>