![]() |
Code for post background not working
I wanted post backgrounds to change based on your rank so I found this.
I created a plug in with this tutorial: Code:
Hey There, The post does not change color like it should, and instead leaves it like it were before. I've already double checked that my id is 6 and it is. Any other ideas? |
I'm not sure -> works with an array. I think maybe you want:
Code:
if($this->post['usergroupid'] == 6) { Code:
<div class="postrow" <vb:if condition="$post[usergroupid] == 6">style="background-color: #ddd"</vb:if>> Another thing you can do, if you wanted to make different colors for different groups (or whatever) is that you could make a class for each one (in additional.css) where the usergroupid is part of the class name, then add a class using the usergroupid as part of it, like: Code:
<div class="postrow postbg_{vb:raw post.usergroupid}"> and then in the css: Code:
.postbg_6 { |
All times are GMT. The time now is 03:27 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 | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|