Skip to content

Commit

Permalink
Merge pull request #672 from emanuele45/message_preview_drop
Browse files Browse the repository at this point in the history
Message preview drop
  • Loading branch information
norv committed Jul 18, 2013
2 parents bb19b42 + 0f77cca commit 5ab91f0
Show file tree
Hide file tree
Showing 5 changed files with 12 additions and 11 deletions.
2 changes: 1 addition & 1 deletion themes/default/MessageIndex.template.php
Expand Up @@ -284,7 +284,7 @@ function template_main()

echo '
<h4>
', $topic['is_sticky'] ? '<strong>' : '', '<span class="preview" title="', $topic[(empty($settings['message_index_preview_first']) ? 'last_post' : 'first_post')]['preview'], '"><span id="msg_' . $topic['first_post']['id'] . '">', $topic['first_post']['link'], ($context['can_approve_posts'] && !$topic['approved'] ? '&nbsp;&nbsp;<em><img src="' . $settings['images_url'] . '/admin/post_moderation_moderate.png" style="width:16px" alt="' . $txt['awaiting_approval'] . '" title="' . $txt['awaiting_approval'] . '" />(' . $txt['awaiting_approval'] . ')</em>' : ''), '</span></span>', $topic['is_sticky'] ? '</strong>' : '', '
', $topic['is_sticky'] ? '<strong>' : '', '<span class="preview" title="', $topic[(!empty($settings['message_index_preview']) && $settings['message_index_preview_first'] == 2 ? 'last_post' : 'first_post')]['preview'], '"><span id="msg_' . $topic['first_post']['id'] . '">', $topic['first_post']['link'], ($context['can_approve_posts'] && !$topic['approved'] ? '&nbsp;&nbsp;<em><img src="' . $settings['images_url'] . '/admin/post_moderation_moderate.png" style="width:16px" alt="' . $txt['awaiting_approval'] . '" title="' . $txt['awaiting_approval'] . '" />(' . $txt['awaiting_approval'] . ')</em>' : ''), '</span></span>', $topic['is_sticky'] ? '</strong>' : '', '
</h4>
</div>
<p class="topic_starter">
Expand Down
4 changes: 2 additions & 2 deletions themes/default/Recent.template.php
Expand Up @@ -150,7 +150,7 @@ function template_unread()
echo '
<a href="', $topic['new_href'], '" id="newicon', $topic['first_post']['id'], '"><span class="new_posts">' . $txt['new'] . '</span></a>
<h4>
', $topic['is_sticky'] ? '<strong>' : '', '<span class="preview" title="', $topic[(empty($settings['message_index_preview_first']) ? 'last_post' : 'first_post')]['preview'], '"><span id="msg_' . $topic['first_post']['id'] . '">', $topic['first_post']['link'], '</span></span>', $topic['is_sticky'] ? '</strong>' : '', '
', $topic['is_sticky'] ? '<strong>' : '', '<span class="preview" title="', $topic[(!empty($settings['message_index_preview']) && $settings['message_index_preview_first'] == 2 ? 'last_post' : 'first_post')]['preview'], '"><span id="msg_' . $topic['first_post']['id'] . '">', $topic['first_post']['link'], '</span></span>', $topic['is_sticky'] ? '</strong>' : '', '
</h4>
</div>
<p class="topic_starter">
Expand Down Expand Up @@ -277,7 +277,7 @@ function template_replies()
echo '
<a href="', $topic['new_href'], '" id="newicon', $topic['first_post']['id'], '"><span class="new_posts">' . $txt['new'] . '</span></a>
<h4>
', $topic['is_sticky'] ? '<strong>' : '', '<span title="', $topic[(empty($settings['message_index_preview_first']) ? 'last_post' : 'first_post')]['preview'], '"><span id="msg_' . $topic['first_post']['id'] . '">', $topic['first_post']['link'], '</span></span>', $topic['is_sticky'] ? '</strong>' : '', '
', $topic['is_sticky'] ? '<strong>' : '', '<span title="', $topic[(!empty($settings['message_index_preview']) && $settings['message_index_preview_first'] == 2 ? 'last_post' : 'first_post')]['preview'], '"><span id="msg_' . $topic['first_post']['id'] . '">', $topic['first_post']['link'], '</span></span>', $topic['is_sticky'] ? '</strong>' : '', '
</h4>
</div>
<p class="topic_starter">
Expand Down
10 changes: 5 additions & 5 deletions themes/default/Settings.template.php
Expand Up @@ -291,11 +291,11 @@ function template_settings()
array(
'id' => 'message_index_preview',
'label' => $txt['message_index_preview'],
),
array(
'id' => 'message_index_preview_first',
'label' => $txt['message_index_preview_first'],
'description' => $txt['message_index_preview_first_desc'],
'options' => array(
0 => $txt['message_index_preview_off'],
1 => $txt['message_index_preview_first'],
2 => $txt['message_index_preview_last'],
),
),
);
}
2 changes: 1 addition & 1 deletion themes/default/languages/Help.english.php
Expand Up @@ -394,7 +394,7 @@
$helptxt['oldTopicDays'] = 'If this option is enabled a warning will be displayed to the user when attempting to reply to a topic which has not had any new replies for the amount of time, in days, specified by this setting. Set this setting to 0 to disable the feature.';
$helptxt['edit_wait_time'] = 'Number of seconds allowed for a post to be edited before logging the last edit date.';
$helptxt['edit_disable_time'] = 'Number of minutes allowed to pass before a user can no longer edit a post they have made. Set to 0 disable. <br /><br /><em>Note: This will not affect any user who has permission to edit other people\'s posts.</em>';
$helptxt['preview_characters'] = 'This option sets the number of available characters for the first and last message topic preview. <strong>Note</strong> this only makes the information available to the theme, the theme must support the message_index_preview setting';
$helptxt['preview_characters'] = 'This option sets the number of available characters for the first and last message topic preview. <strong>Note</strong> this only makes the information available to the theme, the theme must support the &quot;Show post previews on the message index&quot; setting';
$helptxt['posts_require_captcha'] = 'This setting will force users to pass anti-spam bot verification each time they make a post to a board. Only users with a post count below the number set will need to enter the code - this should help combat automated spamming scripts.';
$helptxt['enableSpellChecking'] = 'Enable spell checking. You MUST have the pspell library installed on your server and your PHP configuration set up to use the pspell library. Your server ' . (function_exists('pspell_new') ? 'DOES' : 'DOES NOT') . ' appear to have this set up.';
$helptxt['disable_wysiwyg'] = 'This setting disallows all users from using the WYSIWYG (&quot;What You See Is What You Get&quot;) editor on the post page.';
Expand Down
5 changes: 3 additions & 2 deletions themes/default/languages/Themes.english.php
Expand Up @@ -65,8 +65,9 @@
$txt['show_group_key'] = 'Show group key on board index';
$txt['additional_options_collapsable'] = 'Enable collapsible additional post options';
$txt['message_index_preview'] = 'Show post previews on the message index';
$txt['message_index_preview_first'] = 'When using post previews, Show the text of the first post';
$txt['message_index_preview_first_desc'] = 'Leave un-checked to show the text of the last post instead';
$txt['message_index_preview_off'] = 'Do not show the previews';
$txt['message_index_preview_first'] = 'Show the text of the first post';
$txt['message_index_preview_last'] = 'Show the text of the last post';
$txt['allow_no_censored'] = 'Allow users to turn off word censoring';
$txt['who_display_viewing'] = 'Show who is viewing the board index and posts';
$txt['who_display_viewing_off'] = 'Don\'t show';
Expand Down

0 comments on commit 5ab91f0

Please sign in to comment.