Removing the icons beside the message icons in the thread list

Started by thenoss, May 13, 2011, 04:33:39 PM

Previous topic - Next topic

thenoss

Hey guys,

First of all, my forum is running SMF 2.0 RC5 with a custom theme.

Basically what I want to do is:

1. Remove the option for people to pick a message icon when replying but at the same time keep the option to do so while making a new thread.
2. Remove the message icon and the subject of the topic in all replies. (Re: Topic Name Here)

3. Remove the icons beside the message icons in the thread list.


Which files and where exactly do I need to edit?

Thanks!

MrGrumpy

Make sure you back up before you do my edits to be safe as I'm not on my own computer and don't have my files/test site


For the first 1 see this topic http://www.simplemachines.org/community/index.php?topic=432855.0

Second

In MessageIndex.template.php

find

echo '
<tr class="windowbg2">
<td colspan="', !empty($context['can_quick_mod']) ? '6' : '5', '">
<span class="alert">!</span> ', $context['unapproved_posts_message'], '
</td>
</tr>';


replace with

echo '
<tr class="windowbg2">
<td colspan="', !empty($context['can_quick_mod']) ? '5' : '4', '">
<span class="alert">!</span> ', $context['unapproved_posts_message'], '
</td>
</tr>';



find and remove


<td class="icon1 ', $color_class, '">
<img src="', $settings['images_url'], '/topic/', $topic['class'], '.gif" alt="" />
</td>


As I said I'm not on my own computer but just looking at the file and I've got the feeling theres another colspan that needs adjusting, I maybe mixing it up with another similar edit I've done recently as I have worked on something similar so if you make them changes and something breaks try this

find

<tr class="titlebg">
<td colspan="6" align="right">


replace with

<tr class="titlebg">
<td colspan="5" align="right">


the possession of knowledge is worthless unless imparted upon others
My Custom Themes
2.0 themes only - I don't do 1.1.x

thenoss

Thanks for taking the time to help.

I just did the title removal from replies and it worked :), thanks.
I also tried the icon removal and it got rid of them but at the same time broke the layout:



=O


Also, do you know how I could go about removing the option for people to pick a message icon when replying but at the same time keep the option to do so while making a new thread?
Not sure if you missed that one or not! (because of the pictures)

One more request: What do I need to edit in order to remove the message icons in individual posts including the first post?


MrGrumpy

Sorry i didn't see your previous post

Can you attach your boardindex.template.php so i can look at it, I've missed something out, thought i did when i gave you the code, a column setting needs adjusting
the possession of knowledge is worthless unless imparted upon others
My Custom Themes
2.0 themes only - I don't do 1.1.x

thenoss

No problem, here it is:

MrGrumpy

Oooops I asked for the wrong file I needed MessageIndex.template.php - I've attatched an edited copy of the file from the default theme, if the theme you are editing has a unedited MessageIndex.template.php

If not you will need to add this edit to the other edits I told you to do, I had missed a column span adjustment off the original code I posted

Do the following edits and it will work, I've been able to test it this time

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

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

Find
<td colspan="', !empty($context['can_quick_mod']) ? '6' : '5', '" class="smalltext">';

Replace with
<td colspan="', !empty($context['can_quick_mod']) ? '5' : '4', '" class="smalltext">';

Find
<td colspan="', !empty($context['can_quick_mod']) ? '6' : '5', '">

Replace with
<td colspan="', !empty($context['can_quick_mod']) ? '5' : '4', '">

Find and delete
<td class="icon1 ', $color_class, '">
   <img src="', $settings['images_url'], '/topic/', $topic['class'], '.gif" alt="" />
</td>



Find
<td colspan="6" align="right">

Replace with
<td colspan="5" align="right">

Regarding removing the option for repliers to select an icon I can't really help you with, I'm not really much of a coder I'm a themer but i'm sure if you make a new post just for that someone will be able to help.
the possession of knowledge is worthless unless imparted upon others
My Custom Themes
2.0 themes only - I don't do 1.1.x

thenoss

Awesome, the theme doesn't touch the MessageIndex so the file you uploaded worked like a charm!

Thanks for all your help, much appreciated.

I'll go ahead and make that new thread, and once again thanks :}

Advertisement: