| @@ 432-433 (lines=2) @@ | ||
| 429 | // We need to check the topic icons exist... |
|
| 430 | if (!empty($modSettings['messageIconChecks_enable'])) |
|
| 431 | { |
|
| 432 | if (!isset($context['icon_sources'][$row['first_icon']])) |
|
| 433 | $context['icon_sources'][$row['first_icon']] = file_exists($settings['theme_dir'] . '/images/post/' . $row['first_icon'] . '.png') ? 'images_url' : 'default_images_url'; |
|
| 434 | if (!isset($context['icon_sources'][$row['last_icon']])) |
|
| 435 | $context['icon_sources'][$row['last_icon']] = file_exists($settings['theme_dir'] . '/images/post/' . $row['last_icon'] . '.png') ? 'images_url' : 'default_images_url'; |
|
| 436 | } |
|
| @@ 434-435 (lines=2) @@ | ||
| 431 | { |
|
| 432 | if (!isset($context['icon_sources'][$row['first_icon']])) |
|
| 433 | $context['icon_sources'][$row['first_icon']] = file_exists($settings['theme_dir'] . '/images/post/' . $row['first_icon'] . '.png') ? 'images_url' : 'default_images_url'; |
|
| 434 | if (!isset($context['icon_sources'][$row['last_icon']])) |
|
| 435 | $context['icon_sources'][$row['last_icon']] = file_exists($settings['theme_dir'] . '/images/post/' . $row['last_icon'] . '.png') ? 'images_url' : 'default_images_url'; |
|
| 436 | } |
|
| 437 | else |
|
| 438 | { |
|
| @@ 1261-1262 (lines=2) @@ | ||
| 1258 | if (!empty($modSettings['messageIconChecks_enable'])) |
|
| 1259 | { |
|
| 1260 | // First icon first... as you'd expect. |
|
| 1261 | if (!isset($context['icon_sources'][$row['first_icon']])) |
|
| 1262 | $context['icon_sources'][$row['first_icon']] = file_exists($settings['theme_dir'] . '/images/post/' . $row['first_icon'] . '.png') ? 'images_url' : 'default_images_url'; |
|
| 1263 | // Last icon... last... duh. |
|
| 1264 | if (!isset($context['icon_sources'][$row['last_icon']])) |
|
| 1265 | $context['icon_sources'][$row['last_icon']] = file_exists($settings['theme_dir'] . '/images/post/' . $row['last_icon'] . '.png') ? 'images_url' : 'default_images_url'; |
|
| @@ 1264-1265 (lines=2) @@ | ||
| 1261 | if (!isset($context['icon_sources'][$row['first_icon']])) |
|
| 1262 | $context['icon_sources'][$row['first_icon']] = file_exists($settings['theme_dir'] . '/images/post/' . $row['first_icon'] . '.png') ? 'images_url' : 'default_images_url'; |
|
| 1263 | // Last icon... last... duh. |
|
| 1264 | if (!isset($context['icon_sources'][$row['last_icon']])) |
|
| 1265 | $context['icon_sources'][$row['last_icon']] = file_exists($settings['theme_dir'] . '/images/post/' . $row['last_icon'] . '.png') ? 'images_url' : 'default_images_url'; |
|
| 1266 | } |
|
| 1267 | ||
| 1268 | // Force the recycling icon if appropriate |
|
| @@ 570-571 (lines=2) @@ | ||
| 567 | if (!empty($recycle_board) && $topics[$row['id_topic']]['id_board']) |
|
| 568 | $row['icon'] = 'recycled'; |
|
| 569 | ||
| 570 | if (!empty($modSettings['messageIconChecks_enable']) && !isset($icon_sources[$row['icon']])) |
|
| 571 | $icon_sources[$row['icon']] = file_exists($settings['theme_dir'] . '/images/post/' . $row['icon'] . '.png') ? 'images_url' : 'default_images_url'; |
|
| 572 | ||
| 573 | // Build the array. |
|
| 574 | $posts[] = array( |
|
| @@ 1997-1998 (lines=2) @@ | ||
| 1994 | $row['icon'] = 'recycled'; |
|
| 1995 | ||
| 1996 | // Check that this message icon is there... |
|
| 1997 | if (!empty($modSettings['messageIconChecks_enable']) && !isset($icon_sources[$row['icon']])) |
|
| 1998 | $icon_sources[$row['icon']] = file_exists($settings['theme_dir'] . '/images/post/' . $row['icon'] . '.png') ? 'images_url' : 'default_images_url'; |
|
| 1999 | ||
| 2000 | censorText($row['subject']); |
|
| 2001 | censorText($row['body']); |
|
| @@ 1405-1406 (lines=2) @@ | ||
| 1402 | if (empty($modSettings['messageIconChecks_disable'])) |
|
| 1403 | { |
|
| 1404 | // If the current icon isn't known, then we need to do something... |
|
| 1405 | if (!isset($context['icon_sources'][$message['icon']])) |
|
| 1406 | $context['icon_sources'][$message['icon']] = file_exists($settings['theme_dir'] . '/images/post/' . $message['icon'] . '.png') ? 'images_url' : 'default_images_url'; |
|
| 1407 | } |
|
| 1408 | elseif (!isset($context['icon_sources'][$message['icon']])) |
|
| 1409 | $context['icon_sources'][$message['icon']] = 'images_url'; |
|
| @@ 1993-1994 (lines=2) @@ | ||
| 1990 | // Sadly, we need to check the icon ain't broke. |
|
| 1991 | if (!empty($modSettings['messageIconChecks_enable'])) |
|
| 1992 | { |
|
| 1993 | if (!isset($context['icon_sources'][$message['first_icon']])) |
|
| 1994 | $context['icon_sources'][$message['first_icon']] = file_exists($settings['theme_dir'] . '/images/post/' . $message['first_icon'] . '.png') ? 'images_url' : 'default_images_url'; |
|
| 1995 | if (!isset($context['icon_sources'][$message['last_icon']])) |
|
| 1996 | $context['icon_sources'][$message['last_icon']] = file_exists($settings['theme_dir'] . '/images/post/' . $message['last_icon'] . '.png') ? 'images_url' : 'default_images_url'; |
|
| 1997 | if (!isset($context['icon_sources'][$message['icon']])) |
|
| @@ 1995-1996 (lines=2) @@ | ||
| 1992 | { |
|
| 1993 | if (!isset($context['icon_sources'][$message['first_icon']])) |
|
| 1994 | $context['icon_sources'][$message['first_icon']] = file_exists($settings['theme_dir'] . '/images/post/' . $message['first_icon'] . '.png') ? 'images_url' : 'default_images_url'; |
|
| 1995 | if (!isset($context['icon_sources'][$message['last_icon']])) |
|
| 1996 | $context['icon_sources'][$message['last_icon']] = file_exists($settings['theme_dir'] . '/images/post/' . $message['last_icon'] . '.png') ? 'images_url' : 'default_images_url'; |
|
| 1997 | if (!isset($context['icon_sources'][$message['icon']])) |
|
| 1998 | $context['icon_sources'][$message['icon']] = file_exists($settings['theme_dir'] . '/images/post/' . $message['icon'] . '.png') ? 'images_url' : 'default_images_url'; |
|
| 1999 | } |
|
| @@ 1997-1998 (lines=2) @@ | ||
| 1994 | $context['icon_sources'][$message['first_icon']] = file_exists($settings['theme_dir'] . '/images/post/' . $message['first_icon'] . '.png') ? 'images_url' : 'default_images_url'; |
|
| 1995 | if (!isset($context['icon_sources'][$message['last_icon']])) |
|
| 1996 | $context['icon_sources'][$message['last_icon']] = file_exists($settings['theme_dir'] . '/images/post/' . $message['last_icon'] . '.png') ? 'images_url' : 'default_images_url'; |
|
| 1997 | if (!isset($context['icon_sources'][$message['icon']])) |
|
| 1998 | $context['icon_sources'][$message['icon']] = file_exists($settings['theme_dir'] . '/images/post/' . $message['icon'] . '.png') ? 'images_url' : 'default_images_url'; |
|
| 1999 | } |
|
| 2000 | else |
|
| 2001 | { |
|