vBulletin Mods

The Official vBulletin Modifications Site
https://www.vbulletin.org/forum/showthread.php?t=293417

Change Background Color for Specific Forums on Homepage
by addamroy
30 Dec 2012 01:37

This modification will allow you to change the background color of specific forums on your forumhome.

For example, if you want to draw more attention to your private sections to drive paid registrations, this can help.

This mod is done via one simple template edit.

STEP 1 - Find the forumhome_forumbit_level2_post template via edit templates > Forum Home Templates.

Find the code below

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

And replace it with

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

Replace XXX with the forumid of the forum you want to change the background color of.

Replace xxxxxx to the hex code of the color you want to use. You can find hex codes here, http://www.html-color-codes.com

If you have multiple forums you want to change the background colors of for each, simply stack additional vb:if conditions before the > for each forum you want to change.

Like below

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

Straight forward, works like a charm.

Check out my other Template Modifications for 4.x!

[Postbit-Legacy Hack] Attractive User Info Boxes for Posts

Link Private Forums to thread instead of error message

Sidebar Anywhere Enhancement - Custom Blocks Per Forum or Page

Change Thread Title Color for Specific Forums on Homepage

Change Title Color of Specific Forums on Homepage

Thread Starter Image in Postbit for OP

CUSTOM BUTTONS that look like your forum!

Custom User Rank Box in Posts

astdirect 26 Mar 2013 15:49

Didn't work for me im afraid - no change.

masonox 19 May 2013 15:29

Best I've been able to do with only a minute of work is change it to this to change text color. I haven't tried working with background colors, but I'm sure the html is simple.

<vb:if condition="$forum[forumid] == XXX">
<span style="color:XXXX">
</vb:if>

faisaly.com 01 Jun 2013 18:25

does not work using vb4.1.11 just added the simple code....

edytwinky 13 Jun 2013 21:17

Is this working for anybody?

addamroy 18 Jun 2013 13:13

I re worked the code a little bit, try again.

Raptor 24 Oct 2017 23:20

not working in vb 4.2.3

ShawneyJ 25 Oct 2017 09:17

1 Attachment(s)
Works ok on my test board Version 4.2.5.

Raptor 19 Nov 2019 05:28

this worked perfectly - simply add to the themes additional.css

XXX is the forum ID, #FFFFFF is the color

#catXXX .forumhead {
background: #FFFFFF !important;
}


Thanks to MarkL

Raptor 19 Nov 2019 12:26

Add this code to additional.css and it will change the background color of the header, the topic title, and the topic description

Simply add the forum ID and colors :)

Example:

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

Tested with vb4.2.5


All times are GMT. The time now is 13:24.

Powered by vBulletin® Version 3.8.14
Copyright © 2020, MH Sub I, LLC dba vBulletin. All Rights Reserved. vBulletin® is a registered trademark of MH Sub I, LLC
Copyright ©2001 - , vbulletin.org. All rights reserved.