| @@ 55-60 (lines=6) @@ | ||
| 52 | $context['messages_per_page'] = empty($modSettings['disableCustomPerPage']) && !empty($options['messages_per_page']) ? $options['messages_per_page'] : $modSettings['defaultMaxMessages']; |
|
| 53 | ||
| 54 | // Let's do some work on what to search index. |
|
| 55 | if (count($_GET) > 2) |
|
| 56 | foreach ($_GET as $k => $v) |
|
| 57 | { |
|
| 58 | if (!in_array($k, array('topic', 'board', 'start', session_name()))) |
|
| 59 | $context['robot_no_index'] = true; |
|
| 60 | } |
|
| 61 | ||
| 62 | if (!empty($_REQUEST['start']) && (!is_numeric($_REQUEST['start']) || $_REQUEST['start'] % $context['messages_per_page'] != 0)) |
|
| 63 | $context['robot_no_index'] = true; |
|
| @@ 71-79 (lines=9) @@ | ||
| 68 | $context['maxindex'] = isset($_REQUEST['all']) && !empty($modSettings['enableAllMessages']) ? $board_info['total_topics'] : $context['topics_per_page']; |
|
| 69 | ||
| 70 | // Right, let's only index normal stuff! |
|
| 71 | if (count($_GET) > 1) |
|
| 72 | { |
|
| 73 | $session_name = session_name(); |
|
| 74 | foreach ($_GET as $k => $v) |
|
| 75 | { |
|
| 76 | if (!in_array($k, array('board', 'start', $session_name))) |
|
| 77 | $context['robot_no_index'] = true; |
|
| 78 | } |
|
| 79 | } |
|
| 80 | if (!empty($_REQUEST['start']) && (!is_numeric($_REQUEST['start']) || $_REQUEST['start'] % $context['messages_per_page'] != 0)) |
|
| 81 | $context['robot_no_index'] = true; |
|
| 82 | ||