vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 Design and Graphics Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=168)
-   -   Different Background colors per forum? (https://vborg.vbsupport.ru/showthread.php?t=242225)

kjsmith84 05-10-2010 06:17 PM

Different Background colors per forum?
 
I was wondering what I need to do to have different background colors per forum ids?

if possiable- or even change the colors of the different modules I have for cmps.

Lynne 05-10-2010 07:31 PM

Several ways to do it
- Get the class, and add a line in the FORUMDISPLAY template to change the background for the class.
- Use a plugin and add the background for the class.
- Use a different style for that forum.

kjsmith84 05-10-2010 10:14 PM

Quote:

Originally Posted by Lynne (Post 2034693)
Several ways to do it
- Get the class, and add a line in the FORUMDISPLAY template to change the background for the class.
- Use a plugin and add the background for the class.
- Use a different style for that forum.

ok thanks.

in the forum display template would you happen to know the code I would need to enter?

Lynne 05-11-2010 03:18 AM

Real basic....
HTML Code:

<if condition="$forumid == x">
<style type="text/css">
yourclass {background: pink;}
</style>
</if>


kjsmith84 05-11-2010 03:04 PM

Quote:

Originally Posted by Lynne (Post 2034898)
Real basic....
HTML Code:

<if condition="$forumid == x">
<style type="text/css">
yourclass {background: pink;}
</style>
</if>


hmmm tried it and seemed not to work?

Lynne 05-11-2010 06:56 PM

*Exactly* what did you put and where?

kjsmith84 05-11-2010 07:42 PM

Quote:

Originally Posted by Lynne (Post 2035321)
*Exactly* what did you put and where?

well to test it I just tried to put it on the top of the forumdisplay

<if condition="$forumid == 1">
<style type="text/css">
yourclass {background: pink;}
</style>
</if>

Lynne 05-12-2010 02:33 AM

You can't just put that at the top of FORUMDISPLAY. It needs to go within the <head> tags. Also, I told you to find the class you need to change. I *know* it is not called "yourclass" So, there is no way that will work if you don't put in a valid class.

kjsmith84 05-12-2010 01:38 PM

Quote:

Originally Posted by Lynne (Post 2035477)
You can't just put that at the top of FORUMDISPLAY. It needs to go within the <head> tags. Also, I told you to find the class you need to change. I *know* it is not called "yourclass" So, there is no way that will work if you don't put in a valid class.


ok not sure if this is right but its not working.

couldnt fit all the code but here is where I put it in forumdisplay

<if condition="$forumid == 110">
<style type="text/css">
.forumdisplay{color: pink;}
</style>
</if>

kjsmith84 10-19-2010 03:45 PM

1 Attachment(s)
This is something I still need to figure out- can some one help me a bit more- I have attached a picture of what im wanting to do.

I have my site set up similar to here-vb.org and and I want each seperate cat of forums to have a different color - I think it is the tcat class?

same thing with in the threads them self too.

my site
www.SXS411.com

still have a bunch of stuff still need to be done but trying to get a few of the little things done


Thanks!!

BirdOPrey5 10-23-2010 11:59 AM

Quote:

Originally Posted by kjsmith84 (Post 2035739)
ok not sure if this is right but its not working.

couldnt fit all the code but here is where I put it in forumdisplay

<if condition="$forumid == 110">
<style type="text/css">
.forumdisplay{color: pink;}
</style>
</if>

Quote:

Originally Posted by kjsmith84 (Post 2111690)
This is something I still need to figure out- can some one help me a bit more- I have attached a picture of what im wanting to do.

I have my site set up similar to here-vb.org and and I want each seperate cat of forums to have a different color - I think it is the tcat class?

same thing with in the threads them self too.

my site
www.SXS411.com

still have a bunch of stuff still need to be done but trying to get a few of the little things done


Thanks!!

You need to re-read what Lynne said and follow the instructions...
You CAN NOT put this code in the forumdisplay template
You must find for yourself the name of the class, it is NOT "yourclass" nor "forumdisplay." forumdisplay is a template name and NOT the template you need to add this code. You must add it to the HEADER so use "headinclude" template.

kjsmith84 10-25-2010 02:37 PM

Quote:

Originally Posted by BirdOPrey5 (Post 2113143)
You need to re-read what Lynne said and follow the instructions...
You CAN NOT put this code in the forumdisplay template
You must find for yourself the name of the class, it is NOT "yourclass" nor "forumdisplay." forumdisplay is a template name and NOT the template you need to add this code. You must add it to the HEADER so use "headinclude" template.


ok so I tried

Code:

<if condition="$forumid == 1">
<style type="text/css">
tcat {background: pink;}
</style>
</if>

and it sees to work- what if I wanted to add more then one forum id to that color?


whould I use array>

Quote:

if condition="in_array($foruminfo['forumid'], array(147,1,3))

BirdOPrey5 10-25-2010 03:03 PM

yes... the array should work but just use $forumid not $foruminfo['forumid'] if $forumid is already working for you.

kjsmith84 10-25-2010 03:38 PM

1 Attachment(s)
Quote:

Originally Posted by BirdOPrey5 (Post 2114004)
yes... the array should work but just use $forumid not $foruminfo['forumid'] if $forumid is already working for you.

well i used what I posted and it works for the most part but .tcat doesnt do the subfoums

you can see that they are still blue. not sure what class that is- tried .thead, td.thead, div.thead, th.thead and non worked- so im not sure what works?

BirdOPrey5 10-25-2010 08:39 PM

Looks like it's .cat1

kjsmith84 10-27-2010 03:01 PM

Quote:

Originally Posted by BirdOPrey5 (Post 2114135)
Looks like it's .cat1

worked! thanks!


All times are GMT. The time now is 10:20 PM.

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.01321 seconds
  • Memory Usage 1,758KB
  • 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
  • (1)bbcode_code_printable
  • (2)bbcode_html_printable
  • (10)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (16)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