MyBB Community Forums

Full Version: inbuilt Function to get uid from username and vice versa
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hello ,

Can i know is there a inbuilt Function to get uid from username and vice versa

did with getuser() we can get the username if we supply the uid? am i right?

my questions
1. what is the inbuilt function to Get uid if we have username
2. what is the inbuilt function to Get username if we have uid


how it is possible
You can use database methods to execute a simple SQL query to do what you want.
http://wiki.mybboard.net/index.php/Database_Methods

I don't know if there is pre-written functionality in MyBB to do this.
(2010-02-21, 09:06 AM)TimB. Wrote: [ -> ]You can use database methods to execute a simple SQL query to do what you want.
http://wiki.mybboard.net/index.php/Database_Methods

I don't know if there is pre-written functionality in MyBB to do this.

i know that , but anyway ,thanks for replying, i am looking for inbuilt function like getuser()
There isn't one to get the uid from the username, because the forum only really works with uids in the code, it never needs to get the uid from the username.