Uploaded image for project: 'phpBB'
  1. phpBB
  2. PHPBB-10967

PHPBB_USE_BOARD_URL_PATH not implemented in posting_gen_topic_icons

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Trivial Trivial
    • 3.0.12-RC1
    • 3.0.10
    • None
    • None

      Hello,

      First I have to say that this is merely a bug, but since it's not a feature request either, and trivial to fix, here it the report.

      As it is, the posting_gen_topic_icons (functions_posting.php) does implement PHPBB_USE_BOARD_URL_PATH constant and therefore never generate fully qualified url for the icons.

      Fix :
      Find :

       		foreach ($icons as $id => $data)
      		{
      			if ($data['display'])
      			{
      

      Before add :

       		$root_path = (defined('PHPBB_USE_BOARD_URL_PATH') && PHPBB_USE_BOARD_URL_PATH) ? generate_board_url() . '/' : $phpbb_root_path;
      

      Find :

      					'ICON_IMG'		=> $phpbb_root_path . $config['icons_path'] . '/' . $data['img'],

      Replace with :

      					'ICON_IMG'		=> $root_path . $config['icons_path'] . '/' . $data['img'],

      Regards,

      dcz

            Oleg Oleg [X] (Inactive)
            dcz dcz [X] (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved: