2014-03-22, 02:06 AM
This is a work in progress, this is not complete, nor 100% accurate. Requested from this thread post. I made this mainly as a reference for me however may be useful for new plugin developers.
User $mybb->user['xxx']
Version $mybb->version
Usergroup $mybb->usergroup['xxx']
User $mybb->user['xxx']
- uid - Returns the currently logged in user's UID from the database (example: 1)
- username - Returns the currently logged in user's username from the database (example: Miah)
- password - Returns the currently logged in user's encrypted password from the database (example: 1575c0734578538326)
- salt - Returns the currently logged in user's custom salt used to decrypt the password during login (example: 5kVI8A7U)
- email - Returns the currently logged in user's email from the database (example: [email protected])
- postnum - Returns the currently logged in user's post number from the database (example: 100)
- avatar - Returns the currently logged in user's avatar from the database (example: ./directory/avatar.jpg?dateline=#)
- avatardimensions - Returns the currently logged in user's avatar dimensions seperate by a '|' (example: 200|200)
- avatartype - Returns the currently logged in user's avatar type (example: upload)
- usergroup - Returns the currently logged in user's usergroup (example: 4)
- additionalgroups - Returns the currently logged in user's additional usergroups separated by a comma (example: 3,2)
- displaygroup - Returns the currently logged in user's display group (example: 4)
- usertitle - Returns the currently logged in user's user title (example: MyBB Staff)
- regdate - Returns the currently logged in user's registration date in time() format (example: 1394565678)
- lastactive - Returns the currently logged in user's last active time in time() format (example: 1387347924)
- lastvisit - Returns the currently logged in user's last visit time in time() format (example: 1383729820)
- lastpost - Returns the currently logged in user's last post time in time() format (example: 1383792830)
- website - Returns the currently logged in user's website if specified (example: http://www.mybb.com)
- icq, msn, aim, yahoo - Returns the currently logged in user's instant messager accounts if specified (example: miah)
- birthday - Returns the currently logged in user's birthday (hidden or not, example: 1-12-1990 [day-month-year])
- birthdayprivacy - Returns the currently logged in user's privacy settings for birthday (example: all)
- signature - Returns the currently logged in user's signature if added (example: Miah's Signature)
- allownotices - Returns the currently logged in user's notice settings
- invisible - Returns the currently logged in user's invisible status (1 = yes, 0 = no - example: 1)
- receivepms - Returns the currently logged in user's receive settings for PMs (example: 1)
- showsigs, showavatars, showquickreply, showredirect - Returns the currently logged in user's settings (example: 1)
- referrer - Returns the currently logged in user's referrer if any (example: 4)
- referrals - Returns the currently logged in user's referral amount (example: 2)
- reputation - Returns the currently logged in user's reputation amount (example: 392)
- regip - Returns the currently logged in user's IP in which they registered with (example: 127.0.0.1)
- lastip - Returns the currently logged in user's IP in which they were last active with (example: 127.0.0.1)
- timeonline - Returns the currently logged in user's total active time in time() format (example: 1383792830)
- totalpms - Returns the currently logged in user's total amount of PMs (example: 42)
- unreadpms - Returns the currently logged in user's total amount of unread PMs (example: 10)
- warningpoints - Returns the currently logged in user's total amount of warning points (example: 1)
- ismoderator - Returns the currently logged in user's moderator status (1 = yes, 0 = no, example: 1)
Version $mybb->version
- Returns the current version of MyBB
Usergroup $mybb->usergroup['xxx']
- disporder - The order in which the usergroup will display depending on the number (example: 0)
- isbannedgroup - Returns whether or not the user group is the banned group (example: 1)
- canview - Returns whether or not the user group can view the forum (example: 1)
- canviewthreads - Returns whether or not the user group can view threads (example: 1)
- canviewprofiles - Returns whether or not the user group can view profiles (example: 1)
- candlattachments - Returns whether or not the user group can download attachments (example: 1)
- canpostthreads - Returns whether or not the user group can post threads (example: 1)
- canpostreplys - Returns whether or not the user group can post replies (example: 1)
- canpostattachments - Returns whether or not the user group can post attachments (example: 1)
- canratethreads - Returns whether or not the user group can rate threads (example: 1)