vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 General Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=111)
-   -   Alternating background color for posts. (https://vborg.vbsupport.ru/showthread.php?t=70631)

OrangeFlea 10-15-2004 06:03 PM

Alternating background color for posts.
 
You've seen them: Goes from light to dark to light with each reply.

I have vb 3.0.3 and was wondering how I could go about activating it or getting a hack for it?

Zachery 10-15-2004 06:11 PM

Quote:

Originally Posted by OrangeFlea
You've seen them: Goes from light to dark to light with each reply.

I have vb 3.0.3 and was wondering how I could go about activating it or getting a hack for it?

<if condition="$post[postcount] % 2">alt1<else />alt2</if>

in your postbit or postbit legacy template, find each occurence of alt1 and alt2 and replace it with the above code.

OrangeFlea 10-15-2004 06:15 PM

I remember you telling me this at vb.com. This will change the background color of the ENTIRE post, not just the area where the avatar and little icons are housed, right?

OrangeFlea 10-15-2004 06:22 PM

Ok, did it. Works like a charm, however, can we make the quote background work in conjunction with the change? The background from the quote field is naturally dark, and it doesn't stand out in those posts that are now darker.

Zachery 10-15-2004 06:42 PM

Quote:

Originally Posted by OrangeFlea
Ok, did it. Works like a charm, however, can we make the quote background work in conjunction with the change? The background from the quote field is naturally dark, and it doesn't stand out in those posts that are now darker.

You could assign a new even lighter class, i am not sure if its possible to pass on the that conditional to that template.


All times are GMT. The time now is 08:04 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.00939 seconds
  • Memory Usage 1,717KB
  • 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
  • (2)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (5)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