vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 4.x Template Modifications (https://vborg.vbsupport.ru/forumdisplay.php?f=246)
-   -   Forum Home Enhancements - Change Thread Title Color for Specific Forums on Homepage (https://vborg.vbsupport.ru/showthread.php?t=293431)

addamroy 12-29-2012 11:00 PM

Change Thread Title Color for Specific Forums on Homepage
 
1 Attachment(s)
This modification will allow you to change the color of the thread titles for specific forums on your forumhome in the last post by areas.

This mod is done via one simple template edit.

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

STEP 2 - Find the code below
Code:

<a href="{vb:link thread, {vb:raw threadinfo}, {vb:raw pageinfo_lastpost}}#post{vb:raw lastpostinfo.lastpostid}"><img src="{vb:stylevar imgdir_button}/lastpost-{vb:stylevar right}.png" alt="{vb:rawphrase go_to_last_post}" /></a>
STEP 2 - Before it add
Code:

<vb:if condition="$forum[forumid] == XXX">
<font color="#XXXXXX">
</vb:if>

STEP 3 - After it add
Code:

<vb:if condition="$forum[forumid] == XXX">
</font>
</vb:if>

Replace both instances of XXX with the forumid of the forum you want to change the thread title color of.

Replace XXXXXX with the hex code for the color you want the thread title colors to be.

If you have multiple forums you want to change the thread title colors for on the homepage, simply stack additional vb:if conditions above and below just like above for each forum you want to change.

Like follows

Find the code below
Code:

<a href="{vb:link thread, {vb:raw threadinfo}, {vb:raw pageinfo_lastpost}}#post{vb:raw lastpostinfo.lastpostid}"><img src="{vb:stylevar imgdir_button}/lastpost-{vb:stylevar right}.png" alt="{vb:rawphrase go_to_last_post}" /></a>
Before it add
Code:

<vb:if condition="$forum[forumid] == XXX">
<font color="#XXXXXX">
</vb:if>
<vb:if condition="$forum[forumid] == XXX">
<font color="#XXXXXX">
</vb:if>
<vb:if condition="$forum[forumid] == XXX">
<font color="#XXXXXX">
</vb:if>

After it add
Code:

<vb:if condition="$forum[forumid] == XXX">
</font>
</vb:if>
<vb:if condition="$forum[forumid] == XXX">
</font>
</vb:if>
<vb:if condition="$forum[forumid] == XXX">
</font>
</vb:if>

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 Background 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

sodasusu 12-22-2013 10:46 AM

lets try

Raptor 11-19-2019 09:59 AM

Not working with vb 4.2.3 :/

Raptor 11-19-2019 10:24 AM

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:
Code:

#cat374 .forumhead {
        background: #2491BF !important;
}
#cat374 .forumbit_post .forumtitle a {
    color: #2491BF !important;
}
#cat374 .forumbit_post .forumdescription {
    color: #373737 !important;
}

Tested with vb4.2.5


All times are GMT. The time now is 05:05 AM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01084 seconds
  • Memory Usage 1,722KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (7)bbcode_code_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (4)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete