MyBB Community Forums

Full Version: Alignment Additional Usergroup Images
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hello guys/girls,

I'm using this plugin:
http://mods.mybb.com/view/additional-usergroup-images

I altered it, so it works on both profile and postbit. Thanks to MyBB forums of course.

But now there is a minor thing that I'd like to fix.
[Image: NotAligned.png]

The alignment in the profile section works perfectly, only the alignment in the postbit sections aren't great.

You've got a solution?

Postbit (Classic):
<strong><span class="largetext">{$post['profilelink']}</span></strong> </br>
		<span class="smalltext">
			{$post['usertitle']}<br />
			{$post['groupimage']}
			{$post['useravatar']}<br />
			{$post['user_details']}{$post['newpoints_postbit']}
		</span>


Profile:
<span class="largetext"><strong>{$formattedname}</strong></span></br>

({$usertitle})</br>{$userpagelink}
<span class="smalltext">

{$groupimage}{$gi}

<br />
<strong>{$lang->registration_date}</strong> {$memregdate}<br />
<strong>{$lang->date_of_birth}</strong> {$membday} {$membdayage}<br />
<strong>{$lang->local_time}</strong> {$localtime}<br />
<strong>{$lang->postbit_status}</strong> {$online_status}
</span>

Plugin:
function aui_profile()
{
	global $templates, $theme, $xfire, $memprofile, $mybb, $db, $memprofile, $gi;
	$gids = $memprofile['additionalgroups'];
	$gids = explode(",",$gids);
	$gi = "";
	foreach($gids as $gid)
	{
	$getaui=$db->query("SELECT image FROM ".TABLE_PREFIX."usergroups WHERE gid='".$gid."'");
	$getaui=$db->fetch_array($getaui);
	$aui = $getaui['image'];
	if($aui != "")
	{
	$gi = $gi."<img src='$aui'><br />";
	}	
	}
}

function aui_post(&$post)
{
	global $templates, $theme, $xfire, $memprofile, $mybb, $db, $auigi, $gi, $aui, $memprofile;
	$gids = $post['additionalgroups'];
	$gids = explode(",",$gids);
	$gi = "";
	foreach($gids as $gid)
	{
	$getaui=$db->query("SELECT image FROM ".TABLE_PREFIX."usergroups WHERE gid='".$gid."'");
	$getaui=$db->fetch_array($getaui);
	$aui = $getaui['image'];
	if($aui != "")
	{
	if($mybb->user['classicpostbit'] == 1)
	{
	$post['groupimage'] = $post['groupimage']."<img src='$aui'><br />";
	}
	else
	{
	$post['groupimage'] = $post['groupimage']."<br /><img src='$aui'>";
	}
	}	
	}
	
}

Website Profile: http://420.laemersdev.nl/member.php?acti...file&uid=1
Website Thread: http://420.laemersdev.nl/showthread.php?tid=29