News:

Want to get involved in developing SMF, then why not lend a hand on our github!

Main Menu

Deleting Hot Topic Column

Started by Steve, January 23, 2015, 10:30:31 AM

Previous topic - Next topic

Steve

Is it relatively easy, or even possible to delete or hide the column on the topics page that contain the normal post, hot post and very hot post icons?

See attached.

(the pinned and locked icons are not important to me)
DO NOT pm me for support!

Illori

Quote from: Steve on January 23, 2015, 10:30:31 AM
(the pinned and locked icons are not important to me)

are they important to your users?

Steve

Nope. We are an extremely small forum and those images aren't needed. They just clutter up the aesthetics of the board in our opinion.

Just like we don't have any 'no new' icons on the the index page. Don't need them. When there's something new, the new icon is much easier to see.
DO NOT pm me for support!

kat

MessageIndex.template.php For the theme(s).

Kill this block.

Works on mine. :)

<p class="floatleft smalltext">', !empty($modSettings['enableParticipation']) && $context['user']['is_logged'] ? '
<img src="' . $settings['images_url'] . '/topic/my_normal_post.gif" alt="" align="middle" /> ' . $txt['participation_caption'] . '<br />' : '', '
<img src="' . $settings['images_url'] . '/topic/normal_post.gif" alt="" align="middle" /> ' . $txt['normal_topic'] . '<br />
<img src="' . $settings['images_url'] . '/topic/hot_post.gif" alt="" align="middle" /> ' . sprintf($txt['hot_topics'], $modSettings['hotTopicPosts']) . '<br />
<img src="' . $settings['images_url'] . '/topic/veryhot_post.gif" alt="" align="middle" /> ' . sprintf($txt['very_hot_topics'], $modSettings['hotTopicVeryPosts']) . '
</p>

Kindred

or don't even bother editing code...

use css   .icon1 { display:none; }

and K@....   that won't work...   the icon that Steve mentions is not in a <p>, it's in a TD and is controlled by css for 2.0.x
Слaва
Украинi

Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

"Loki is not evil, although he is certainly not a force for good. Loki is... complicated."

kat

Hmmm... It worked, on mine.

Must've been luck!

Custom theme, though.

Kindred

ugh... of course, it's not as easy as I suggested, either because hiding .icon1 just moves everything else over...    and the header section of the table now has to be fixed... otherwise everything gets crammed to the left

Слaва
Украинi

Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

"Loki is not evil, although he is certainly not a force for good. Loki is... complicated."

Antes

Actually you both are talking on different parts of the same page,

K@ is saying the bottom part (aka legend) to show icons meanings
Kindred is saying the part actually Steve needs :D

easy method add this to css td.icon1:{display:none;}.
time consuming method hack messageindex.template and remove stuff out of it.

Kindred

Antes,  I just tried that....   I don't think it quite works, because of the colspan=2 in the thead section....
Слaва
Украинi

Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

"Loki is not evil, although he is certainly not a force for good. Loki is... complicated."

Antes

ok I just wrote that blindly :P

MessageIndex.template
Code (Find) Select
<th scope="col" class="first_th" width="8%" colspan="2">&nbsp;</th>
Code (Replace) Select
<th scope="col" class="first_th" width="8%" colspan="1">&nbsp;</th>

Code (Find & Delete) Select
<td class="icon1 ', $color_class, '">
<img src="', $settings['images_url'], '/topic/', $topic['class'], '.gif" alt="" />
</td>

Steve

Doing what Antes posted last is close but it makes it look like the two columns have been joined, in other words, the width of the now single column is the same as the original two columns put together.

I was hoping on the width being only as wide as one of the original columns ... if that makes any sense.

I imagine that'll screw up the alignment of everything else?
DO NOT pm me for support!

Antes

<th scope="col" class="first_th" width="8%" colspan="1">&nbsp;</th>

change 8% to 4%

Steve

#12
Perfect (although I changed the width to 3% ... works beautifully)! You're a gentleman and a scholar! Thanks!
DO NOT pm me for support!

Antechinus

If you like, you can add a tweak that will indicate if the topic is a poll, even without the first column icons, and without the poll icon being set manually in the first post of the topic.

You can also set an icon for topics you have posted.

Steve

DO NOT pm me for support!

Antechinus

I'm doing it this way. This is on a table-less markup but you can drop the same basic code into your table cell. Just ditch the div and use the rest.

<div class="topic_icons">
', $topic['is_poll'] ? '<img src="'. $settings['images_url']. '/icons/poll.png" class="topic_icon" alt="" />' : '<img src="'. $topic['first_post']['icon_url']. '" class="topic_icon" alt="" />', '
', $topic['is_posted_in'] ? '<img src="'. $settings['images_url']. '/icons/fred2.png" class="fred" alt="" />' : '','
</div>


The first line does the poll icon. Second line does the user icon. Fred (who also appears in SMF 2.1 and Elk, unless they have changed his name by now :D) is your user icon. CSS for Fred goes like this (tweak to suit yourself):

.fred {
position: absolute;
z-index: 5;
right: 11px;
bottom: 9px;
}


With the surrounding div (or table cell) being set to position: relative;

Steve

Cool beans. Thanks much for that! ;D
DO NOT pm me for support!

Advertisement: