We are no longer offering accounts on this server. Consider https://gitlab.freedesktop.org/ as a place to host projects.

Commit 36e0dc53 authored by Mike Sheldon's avatar Mike Sheldon

Make popular artists cloud based on loved tracks (removes the need for a...

Make popular artists cloud based on loved tracks (removes the need for a cronjob to create it from scrobbles)
parent 2e74840a
......@@ -23,6 +23,12 @@ require_once('database.php');
require_once('templating.php');
require_once('data/sanitize.php');
require_once('data/Server.php');
require_once('data/TagCloud.php');
$aTagCloud = TagCloud::GenerateTagCloud('loved_tracks', 'artist');
if ($aTagCloud) {
$smarty->assign('tagcloud', $aTagCloud);
}
$smarty->assign('headerfile', 'welcome-header.tpl');
$smarty->assign('welcome', true);
......
......@@ -25,10 +25,9 @@ require_once('data/sanitize.php');
require_once('data/Server.php');
require_once('data/TagCloud.php');
$aTagCloud = TagCloud::GenerateTagCloud(TagCloud::scrobblesTable(), 'artist');
$aTagCloud = TagCloud::GenerateTagCloud('loved_tracks', 'artist');
if ($aTagCloud) {
$smarty->assign('tagcloud', $aTagCloud);
$smarty->assign('tagcloud', $aTagCloud);
}
$smarty->display("popular.tpl");
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment