Rating "; return $html; } public function rating_to_name($rating) { switch($rating) { case 's': return "Safe"; case 'q': return "Questionable"; case 'e': return "Explicit"; default: return "Unknown"; } } } ?>