1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-07-30 21:40:43 +02:00

[ticket/15538] Add iconify source class

PHPBB3-15538
This commit is contained in:
mrgoldy
2019-11-18 17:22:12 +01:00
parent fa8cf86e63
commit 8bac1daba7
3 changed files with 14 additions and 5 deletions

View File

@@ -69,13 +69,22 @@ class icon extends \Twig\Extension\AbstractExtension
{
$type = strtolower($type);
if (empty($icon))
{
return '';
}
switch ($type)
{
case 'font':
case 'iconify':
$source = '';
break;
case 'iconify':
$source = explode(':', $icon);
$source = $source[0];
break;
case 'png':
$board_url = defined('PHPBB_USE_BOARD_URL_PATH') && PHPBB_USE_BOARD_URL_PATH;
$web_path = $board_url ? generate_board_url() . '/' : $environment->get_web_root_path();