MyBB Community Forums

Full Version: add pm button to member list
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Is there a way to add a pm button to the member list?
bumping :3
ACP → Templates & Styles → Templates → [your_theme_name] Templates → Member List Templates → memberlist
search: {$referral_header} and after that add:
<td class="tcat" width="5%" align="center"><span class="smalltext"><strong>PM</strong></span></td>
ACP → Templates & Styles → Templates → [your_theme_name] Templates → Member List Templates → memberlist_user
search: {$referral_bit} and after that add:
<td class="{$alt_bg}" align="center">{$pmcode}</td>
Of course, any place.

Open file ./memberlist.php
search:
$user['lastvisit'] = my_date($mybb->settings['dateformat'], $user['lastactive']).", ".my_date($mybb->settings['timeformat'], $user['lastactive']);
and after that add:
$post['uid'] = $user['uid'];
		$pmcode = '';
		if($user['receivepms'] != 0 && $mybb->settings['enablepms'] != 0 && my_strpos(",".$user['ignorelist'].",", ",".$mybb->user['uid'].",") === false)
		{
			eval("\$pmcode = \"".$templates->get("postbit_pm")."\";");
		}