Commit 90a218f0 authored by Mike Sheldon's avatar Mike Sheldon

Tell htmlentities to use utf-8 and handle quotes

parent 0c25579a
......@@ -59,7 +59,7 @@ class GraphTopArtists extends Graph {
foreach ($tmp as $root => $node)
{
$tmp = '<a href="'.$node['pageurl'].'">';
$tmp .= addslashes(htmlentities($node['artist'])).'</a>';
$tmp .= htmlentities($node['artist'], ENT_QUOTES, 'UTF-8').'</a>';
$artists[] = $tmp;
$artists_data[] = $node['count'];
}
......@@ -109,9 +109,9 @@ class GraphTopTracks extends Graph {
foreach($this->data_buffer as $key => $entry)
{
$tmp_line = '<a href="'.$entry['artisturl'].'">';
$tmp_line .= addslashes(htmlentities($entry['artist'])).'</a>';
$tmp_line .= htmlentities($entry['artist'], ENT_QUOTES, 'UTF-8').'</a>';
$tmp_line .= ' - <a href="'.$entry['trackurl'].'">';
$tmp_line .= addslashes(htmlentities($entry['track'])).'</a>';
$tmp_line .= htmlentities($entry['track'], ENT_QUOTES, 'UTF-8').'</a>';
$listings[] = $entry['freq'];
$tracks[] = $tmp_line;
}
......@@ -172,4 +172,4 @@ class GraphPlaysByDays extends Graph {
}
class GraphTrackPerformance extends Graph {}
\ No newline at end of file
class GraphTrackPerformance extends Graph {}
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