Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove option to disable prev/next #2333

Open
wants to merge 2 commits into
base: development
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
1 change: 0 additions & 1 deletion install/install_1-1.php
Expand Up @@ -2271,7 +2271,6 @@ public function insert_settings()
array('likeMinPosts', '5'),
array('karmaMode', '0'),
array('karmaTimeRestrictAdmins', '1'),
array('enablePreviousNext', '1'),
array('pollMode', '1'),
array('modules_display', 'poll,verification,random'),
array('modules_post', 'poll,attachments,verification,random'),
Expand Down
1 change: 0 additions & 1 deletion sources/admin/ManageTopics.controller.php
Expand Up @@ -143,7 +143,6 @@ private function _settings()
// All, next/prev...
array('int', 'enableAllMessages', 'postinput' => $txt['manageposts_posts'], 'subtext' => $txt['enableAllMessages_zero']),
array('check', 'disableCustomPerPage'),
array('check', 'enablePreviousNext'),
);

call_integration_hook('integrate_modify_topic_settings', array(&$config_vars));
Expand Down
9 changes: 4 additions & 5 deletions sources/controllers/Display.controller.php
Expand Up @@ -264,11 +264,10 @@ public function action_display()
}

// Create a previous next string if the selected theme has it as a selected option.
if ($modSettings['enablePreviousNext'])
$context['links'] += array(
'go_prev' => $scripturl . '?topic=' . $topic . '.0;prev_next=prev#new',
'go_next' => $scripturl . '?topic=' . $topic . '.0;prev_next=next#new'
);
$context['links'] += array(
'go_prev' => $scripturl . '?topic=' . $topic . '.0;prev_next=prev#new',
'go_next' => $scripturl . '?topic=' . $topic . '.0;prev_next=next#new'
);

// Check if spellchecking is both enabled and actually working. (for quick reply.)
$context['show_spellchecking'] = !empty($modSettings['enableSpellChecking']) && function_exists('pspell_new');
Expand Down
4 changes: 2 additions & 2 deletions sources/subs/Topic.subs.php
Expand Up @@ -1134,7 +1134,7 @@ function setTopicNotification($id_member, $id_topic, $on = false)
*/
function previousTopic($id_topic, $id_board, $id_member = 0, $includeUnapproved = false, $includeStickies = true)
{
return topicPointer($id_topic, $id_board, false, $id_member = 0, $includeUnapproved = false, $includeStickies = true);
return topicPointer($id_topic, $id_board, false, $id_member, $includeUnapproved, $includeStickies);
}

/**
Expand All @@ -1148,7 +1148,7 @@ function previousTopic($id_topic, $id_board, $id_member = 0, $includeUnapproved
*/
function nextTopic($id_topic, $id_board, $id_member = 0, $includeUnapproved = false, $includeStickies = true)
{
return topicPointer($id_topic, $id_board, true, $id_member = 0, $includeUnapproved = false, $includeStickies = true);
return topicPointer($id_topic, $id_board, true, $id_member, $includeUnapproved, $includeStickies);
}

/**
Expand Down
1 change: 0 additions & 1 deletion themes/default/languages/english/Admin.english.php
Expand Up @@ -640,7 +640,6 @@
$txt['enableAllMessages'] = 'Max topic size to show "All" posts';
$txt['enableAllMessages_zero'] = '0 to never show "All"';
$txt['disableCustomPerPage'] = 'Disable user defined topic/message count per page';
$txt['enablePreviousNext'] = 'Enable previous/next topic links';

$txt['not_done_title'] = 'Not done yet';
$txt['not_done_reason'] = 'To avoid overloading your server, the process has been temporarily paused. It should automatically continue in a few seconds. If it doesn\'t, please click continue below.';
Expand Down
1 change: 0 additions & 1 deletion themes/default/languages/english/Help.english.php
Expand Up @@ -261,7 +261,6 @@
<dd>Yesterday at 09:36:55 pm</dd>
</dl>';
$helptxt['disableCustomPerPage'] = 'Check this option to stop users from customizing the amount of messages and topics to display per page on the Message Index and Topic Display page respectively.';
$helptxt['enablePreviousNext'] = 'This will show a link to the next and previous topic.';
$helptxt['pollMode'] = 'This selects whether polls are enabled or not. If polls are disabled, the regular topic without their polls are shown.
<br /><br />To choose who can post polls, view polls, and similar, you can allow and disallow those permissions. Remember this if polls don\'t seem to be working.';
$helptxt['enableVBStyleLogin'] = 'This will show a more compact login on every page of the forum for guests.';
Expand Down