Get the username of the logged in admin

xpl0iter

Active member
I am posting something to the database via an addon. I would like to get the information about who posted it. So can anyone help me on this?
 
Just check the usergroup?
XenForo_Model_User -> isMemberOfUserGroup($user, $userGroupIds)
 
I am sorry james I am not really good at this. So if you can elaborate this a little bit more it would be really helpful.
BTW do I get the name of the person who posted it by your method?
 
Code:
<xen:if is="{xen:helper ismemberof, $user, 3}">
Content here
</xen:if>

3 is the usergroupid for Administrators
 
Back
Top Bottom