MyBB Community Forums

Full Version: Private Message unread count color
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hello, at the moment i work on my first MyBB Theme, and my Counter of Unread Messages is White...
Now i want that anyone got a Messages that the Number is not anymore white and change automatically to red,
is the message count higher then 0 change the color automatic to red...
[Image: ArAR5HM.png]

i hope anyone can help me Big Grin
I think you need use Template Conditionals http://mybbhacks.zingaburga.com/showthread.php?tid=260 and use this code:

<if ($mybb->user['pms_unread'])>0 then>
If you have counter higher than 0 use background color red and style it
<else>
If you have counter to 0 use background color black and style it
</if>
Thx, for the plugin work perfectly Big Grin

[Image: BQGLbKk.png]

the code that i use is above the menu code in the Template..

<if ($mybb->user['pms_unread']) >0 then>
<style type="text/css">
#mUnread {
 color: red;
}
</style>
<else>
<style type="text/css">
#mUnread {
 color:#fff;
}
</style>
</if>