MyBB Community Forums

Full Version: Color of postbit
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Basically, is it possible to make this?:
http://i.minus.com/iXI2QmnCJoYZa.jpg
can you put your requirement in words please - do you want the left side table cell to have a specific background color ?
Yes, my bad.
Basically, I want background of admin postbit to be different from other postbits.
^ you can use this guidance
Thank you.
I already saw that tutorial, but my postbit template is different so I don't have:
<td class="trow2 post_content {$unapproved_shade}">
<td class="trow2 post_content post{$usergroup['gid']} {$unapproved_shade}">

etc.
Smile
^ can you please read it once again.
css class post{$usergroup['gid']} is to be added for the cell in the postbit_classic template
and required css style should be added in the global.css of the theme
I've read the whole tutorial a couple of times.



The thing is that I don't even have trow2 in my postbit template and it clearly says

Quote:Note that: You have to place the class
a) after class 'trow2' else the 'trow2' background color will govern.
b) before class'{$unapproved_shade}' so that Unapproved post's color can lead over any user's post.
^ please post your postbit_classic template code in php/code tags
{$ignore_bit}
<a name="pid{$post['pid']}" id="pid{$post['pid']}"></a>
<table border="0" cellspacing="0" cellpadding="6" class="postborder" style="{$post_extra_style} {$post_visibility} margin: 5px 0;" id="post_{$post['pid']}">
	<tr>
	<td class="postcat" align="center" style="padding: 8px 6px 4px 6px;">
<strong>{$post['onlinestatus']}</strong> {$post['profilelink']}</strong></td>
<td class="postcat" valign="middle" style="padding: 8px 6px 4px 6px;"><span class="smalltext">{$post['postdate']}, {$post['posttime']}</span> <a name="edited_by_{$post['pid']}" id="{$post['editedmsg']}"></a>
<div style="float: right; width: auto; vertical-align: top"><span class="smalltext">{$post['posturl']}</span></div>
</tr>

	<tr>
		<td class="trow1" width="17%" valign="top" style="white-space: nowrap; text-align: center; border-right: 1px solid #f0f0f0;">
		{$post['usertitle']}<br />
		<span class="smalltext">
			{$post['useravatar']}
			{$post['groupimage']}
			{$post['user_details']}<br />{$post['myawards']}<br />
			{$post['iplogged']}

		</span>	</td>
	<td class="trow1" valign="top">
		<table width="100%">
			<tr><td>
			<div id="pid_{$post['pid']}" class="post_body">
				{$post['message']}
			<div style="text-align: right; vertical-align: bottom;" id="post_meta_{$post['pid']}">
				<div id="edited_by_{$post['pid']}">{$post['editedmsg']}</div>
			</div>
                         {$post['attachments']}
			 {$post['signature']}
		</td></tr>
	</table>
</td>
</tr>
<tr valign="bottom">
	<td class="postcat" align="left" valign="bottom"><a href="#top" class="postbit" style="margin:0;">Back to top</a></td>
	<td class="postcat" align="right" valign="bottom">
<span class="float_left">{$post['button_email']}{$post['button_pm']}{$post['button_www']}{$post['button_find']}{$post['button_rep']}</span>
<span class="float_right">{$post['button_edit']}{$post['button_quickdelete']}{$post['button_quote']}{$post['button_multiquote']}{$post['button_report']}{$post['button_warn']}{$post['button_reply_pm']}{$post['button_replyall_pm']}{$post['button_forward_pm']}{$post['button_delete_pm']}</span>
</td>
</tr>
</table>
<table border="0" cellspacing="0" cellpadding="6" class="postborder" style="{$post_extra_style} {$post_visibility} margin: 5px 0;" id="post_{$post['pid']}">
if you add the suggested groupID class to above code then it should be applicable for the entire post

<td class="trow1" width="17%" valign="top" style="white-space: nowrap; text-align: center; border-right: 1px solid #f0f0f0;">
if you add the class to above code then it should apply for the left side cell only

<td class="trow1" valign="top">
and if you add that class to above code then it should apply for the right side cell containing the post message.

if there is a mistake / confusion in above suggestions then
you can PM me temporary access to admin panel so that I can check & add the code