![]() |
Alternating Colored Rows in vBulletin 4 [No Plugin]
How to have alternating colored rows (and not columns) in vBulletin 4. After searching around, I found one by William, Very nice work. His solution is for vBulletin 3 but it can be easily ported to vBulletin 4. As I searched, I saw the problem is talked a lot in forums without any solution for vBulletin 4 and so I decided to put together a solution extending William's work.
1. Edit template forumhome_forumbit_level2_postAdd the following code at the top of the template. Code:
<vb:if condition="$altrow =& $GLOBALS['altrow']"></vb:if>Now change the first line (first line before inserting the above code) from Code:
<li id="forum{vb:raw forum.forumid}" class="forumbit_post L2">Code:
<li id="forum{vb:raw forum.forumid}" class="forumbit_post L2 {vb:raw $rowClass}">2. Edit forumhome_forumbit_level1_post / _nopostAdd the following at the top of forumhome_forumbit_level1_post and forumhome_forumbit_level1_nopost template.Code:
<vb:if condition="$altrow =& $GLOBALS['altrow']"></vb:if>3. Edit StylevarsEdit forumrow_firstentry_background and forumrow_background stylevars and make it transparent by deleting Background Color and Background Image.4.Edit CSSNow add the following CSS in the additional.css template. Code:
.altodd {background-color:#eee;}I hope this helps fellow vBulletin forum webmasters. |
Re: Alternating Colored Rows in vBulletin 4 [No Plugin]
Nice tutorial Shabbir!
:) This was a very common question for webmasters at vBulletin.Org forum! ;) Now it has a solution!! Thanks! |
Re: Alternating Colored Rows in vBulletin 4 [No Plugin]
Thanks and if you see someone looking for something now you know what to do?
|
Re: Alternating Colored Rows in vBulletin 4 [No Plugin]
Quote:
|
Re: Alternating Colored Rows in vBulletin 4 [No Plugin]
This is a great work around , however i can not seem to get it working on the forumdisplay page . I.e the sub forums above the threadbits, Any ideas ?
|
Re: Alternating Colored Rows in vBulletin 4 [No Plugin]
You should be. What are you trying on the forumdisplay? I tried myself and it just works fine
|
Re: Alternating Colored Rows in vBulletin 4 [No Plugin]
Quote:
|
Re: Alternating Colored Rows in vBulletin 4 [No Plugin]
Quote:
|
Re: Alternating Colored Rows in vBulletin 4 [No Plugin]
Quote:
So far i have edited what you have mentioned above : forumhome_forumbit_level2_post forumhome_forumbit_level1_post forumhome_forumbit_level2_nopost |
Re: Alternating Colored Rows in vBulletin 4 [No Plugin]
Sorry i meant :
forumhome_forumbit_level1_nopost not forumhome_forumbit_level2_nopost |
| All times are GMT +5.5. The time now is 02:36. |