View Full Version : Different Cell Color for Stickies
Andrew111888
08-13-2006, 10:00 PM
What this modification does is change the td cell background color for a sticky thread when viewing a thread listing.
Please note the screenshots are from my 3.0.x release as there's no reason to make new ones.
Versions:
3.6.0 (https://vborg.vbsupport.ru/showthread.php?t=123939)
3.5.0 (https://vborg.vbsupport.ru/showthread.php?t=94328)
3.0.0 (https://vborg.vbsupport.ru/showthread.php?t=93195)
ericgtr
08-15-2006, 04:17 PM
Neat, I have a slightly different use for this utilizing your code. I want unanswered topics to be highlighted, so I changed
<if condition="$thread['sticky'] == 1">
to
<if condition="$thread[replycount] == 0">
And walla! :)
Thanks, installed.
bongwater
08-24-2006, 01:20 PM
I am running 3.6 Gold and I tried following your attached instructions by looking for the following line in the threadbit:
<td class="alt1" id="td_title_$thread[realthreadid]" title="$thread[preview]">
and it's not found. Can somebody tell me which string of text to find, if 3.6 gold differs from previous versions?
thanks
Andrew111888
08-26-2006, 02:55 AM
I have just confirmed that with a default 3.6.0 gold template, that line is indeed in the threadbit template.
Perhaps your template is out of version?
bongwater
08-26-2006, 09:11 AM
Hmm, I guess I must have been looking at the wrong template , because I found it! This was a quick easy one.
Thanks *clicks install*
Snake
08-30-2006, 04:23 PM
Thanks for the hack! I'll install it right away... :)
StarBuG
10-20-2006, 05:54 PM
I realy liked the Idea from ericgtr
I modified it a little further.
2 options:
1) Highlight only 0 reply threads but no stickies (that is my choice)
<if condition="$thread[replycount] != 0">
<td class="alt1" id="td_threadtitle_$thread[realthreadid]" title="$thread[preview]">
<else />
<if condition="$thread['sticky'] == 1 AND $thread[replycount] == 0">
<td class="alt1" id="td_threadtitle_$thread[realthreadid]" title="$thread[preview]">
<else />
<td class="zeroreplybg" id="td_threadtitle_$thread[realthreadid]" title="$thread[preview]">
</if>
</if>
and for the css
.zeroreplybg
{
background-color: #ebf0d2;
color: #000000;
}
2) highlight both (same colors)
<if condition="$thread[replycount] == 0 OR $thread['sticky'] == 1">
<td class="stickybg" id="td_threadtitle_$thread[realthreadid]" title="$thread[preview]">
<else />
<td class="alt1" id="td_threadtitle_$thread[realthreadid]" title="$thread[preview]">
</if>
and for the css
.stickybg
{
background-color: #ebf0d2;
color: #000000;
}
Thx *install*
craig hughes
11-19-2006, 05:31 PM
Great change...thanks
Nathan2006
11-25-2006, 01:42 AM
Thanks Andrew ;)
Also works really well when using "Separate Sticky and Normal Threads"
Install
SirFlash
03-08-2007, 09:13 PM
works on 3.6.4 thanks
anywares
03-09-2007, 12:41 PM
Neat, I have a slightly different use for this utilizing your code. I want unanswered topics to be highlighted, so I changed
<if condition="$thread['sticky'] == 1">
to
<if condition="$thread[replycount] == 0">
And walla! :)
Thanks, installed.
same here :D
*installed*
Tri@de
03-16-2007, 08:41 AM
There's a way to have this working for all forums/thread/posts?
DiSpy
03-24-2007, 06:33 PM
I found this code in threadbit in v 3.6.5:
<td class="alt1Active" id="td_threadtitle_$thread[realthreadid]" title="$thread[preview]">
and replaced it with this:
<if condition="$thread['sticky'] == 1">
<td class="stickybg" id="td_threadtitle_$thread[realthreadid]" title="$thread[preview]">
<else />
<td class="alt1Active" id="td_threadtitle_$thread[realthreadid]" title="$thread[preview]">
</if>
...and don't forget to add:
.stickybg
{
background-color: #hex;
color: #000000;
}
to your CSS style definitions (and replace #hex with a color).
Atakan KOC
03-26-2007, 06:41 AM
Thanks....
mikewiemholt
04-24-2007, 06:08 AM
Thanks a bunch - instead of using a bg color I used an image which was nice ;)
Thanks again,
iorkara
04-25-2007, 03:21 AM
Great Thanks Clicks Install
Billspaintball
04-27-2007, 03:25 AM
Handy little idea :)
dbembibre
05-18-2007, 08:43 AM
To extend the background in 3.6.x to announce as in the image 35356
In ACP -> Styles & Templates -> Style Manager -> [desired style] -> Edit Templates -> threadbit_announcement
Find
<td class="alt2" colspan="$announcecolspan">
Change to
<td class="stickybg" colspan="$announcecolspan">
For 3.5 versi?n see the following post
https://vborg.vbsupport.ru/showpost.php?p=787101&postcount=13
obmob
06-13-2007, 03:13 PM
Easy to use, thanks! :D
BTW: i think there is a typo in the install file it is this:
<td class="alt1" id="td_threadtitle_$thread[realthreadid]" title="$thread[preview]">
instead of this:
<td class="alt1" id="td_title_$thread[realthreadid]" title="$thread[preview]">
rooney72
06-15-2007, 03:53 AM
I modified advanced .css
.stickybg
{
background-color: #hex;
color: #750B10;
}
But the color is still light blue and NOT red as I want it
yessir
06-23-2007, 11:50 AM
bg color = cell color
color = text color
Dannyloski
07-29-2007, 02:28 AM
I might add this, subscribed for when i get home i can insall ...
Gringos.com
07-30-2007, 05:41 PM
Hey Guys -
I am trying to highlight the 'Sticky' thread topic but not sure how. Is this an FTP or CP (control panel) change? I want to draw attention to my 'Sticky' topics. I'm not a Geek so any details is very much appreciated.
Thanks
rapidphim
08-10-2007, 04:08 PM
I am not able to read the txt file from here. Can some one please make it readable or post directly on the thread?
Also, is this compatible with 3.6.8?
rb290
08-24-2007, 09:12 PM
Yea the .txt is hard to read!
DJ2492
08-25-2007, 10:00 PM
This may be one of the dumbest questions ever but um well I am new to my vB Board and I was wondering where I would install the text that I got inside my text file :erm:
Tom_S
08-29-2007, 03:35 PM
Nice addition ;)
rolloffhill
09-10-2007, 12:38 PM
Works perfect.
frostyIntrepid
09-19-2007, 01:41 AM
I did edit the css file and changed to #hex color but it doesn't seem to be reflecting on my forum.
Any idea guys?
jackiereitz
09-19-2007, 02:54 PM
very quick and easy. Thanks
NeoAntrax
10-05-2007, 07:56 AM
I did edit the css file and changed to #hex color but it doesn't seem to be reflecting on my forum.
Any idea guys?
I'm too :confused:
puregraf
10-26-2007, 05:51 PM
here you go all, or you simply copy all from the notepad and open word pad and past and it will be perfect:
Different Cell Color for Stickies
by Andrew111888
In ACP -> Styles & Templates -> Style Manager -> [desired style] -> Edit Templates -> threadbit
Find the following line:
<td class="alt1" id="td_threadtitle_$thread[realthreadid]" title="$thread[preview]">
and replace it with the following:
<if condition="$thread['sticky'] == 1">
<td class="alt2" id="td_threadtitle_$thread[realthreadid]" title="$thread[preview]">
<else />
<td class="alt1" id="td_threadtitle_$thread[realthreadid]" title="$thread[preview]">
</if>
####################################
####################################
####################################
If that is not enough of an offset, you could also do what I did.
========== STEP 1 ==========
In ACP -> Styles & Templates -> Style Manager -> [desired style] -> Edit Templates -> threadbit
Find the following line:
<td class="alt1" id="td_title_$thread[realthreadid]" title="$thread[preview]">
and replace it with the following:
<if condition="$thread['sticky'] == 1">
<td class="stickybg" id="td_threadtitle_$thread[realthreadid]" title="$thread[preview]">
<else />
<td class="alt1" id="td_threadtitle_$thread[realthreadid]" title="$thread[preview]">
</if>
========== STEP 2 ==========
In ACP -> Styles & Templates -> Style Manager -> [desired style] -> Main CSS -> Additional CSS Definitions
Add the following declaration:
.stickybg
{
background-color: #hex;
color: #000000;
}
and simply replace hex with the desired hexcode.
RedGTiVR6
02-27-2008, 06:10 PM
Anyone know if this will work with 3.7?
DieselMinded
05-09-2008, 02:38 AM
Working Great on 3.7.0 Gold
KAWIE1
07-21-2008, 01:27 AM
Thanks man! My second mod...:D
kpmedia
01-28-2010, 03:26 AM
Works in vB 3.8.2
vBulletin® v3.8.12 by vBS, Copyright ©2000-2025, vBulletin Solutions Inc.