MyBB-Plugins Forums
Profile member's uid variable - Printable Version

+- MyBB-Plugins Forums (http://forums.mybb-plugins.com)
+-- Forum: MyBB General Discussion (http://forums.mybb-plugins.com/Forum-MyBB-General-Discussion)
+--- Forum: Coding Help (http://forums.mybb-plugins.com/Forum-Coding-Help)
+--- Thread: Profile member's uid variable (/Thread-Profile-member-s-uid-variable)



Profile member's uid variable - AmazOuz - 07-03-2015

Hi !
I'm developping a plugin, and i have a function which is launched in member_profile_start (hook).
I need the profile member's uid variable.
I used those ones but don't work :
$memprofile["uid"], $_GET["uid"]
The GET works on MyBB 1.6 but not in 1.8 :/
Please help.


RE: Profile member's uid variable - Omar G. - 07-03-2015

Hook: member_profile_start
MyBB: 1.8+
Code:
PHP Code:
global $mybb;

$uid $mybb->get_input('uid'1);
if(
$uid)
{
    
$memprofile get_user($uid);
}
elseif(
$mybb->user['uid'])
{
    
$memprofile $mybb->user;
}
else
{
    return;
}

print_r($memprofile); 



RE: Profile member's uid variable - AmazOuz - 07-04-2015

Thank you Omar Big Grin +rep
Hope you approve the stuff soon Tongue