How can i get users's profile data?

Started by myseoforum.ru, August 18, 2016, 12:01:48 PM

Previous topic - Next topic

myseoforum.ru


Illori


myseoforum.ru

I founded answer for my question:
Quote$request = $smcFunc['db_query']('', '
            SELECT * FROM
                                `forum_members`
            WHERE id_member = 1'
         );
                        $row = $smcFunc['db_fetch_assoc']($request);
                        echo '<pre>';
                        var_dump($row);
                        echo '</pre>';

Kindred

that may be unnecessary, depending on what you are actually trying to do --- there is a good chance that SMF has already loaded the user's data into one of the existing arrays... or that there is already a built function that does this and loads it into a nice array.
Слaва
Украинi

Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

"Loki is not evil, although he is certainly not a force for good. Loki is... complicated."

Pipke

you can use the global var $user_info


global $user_info;

echo '<pre>';
print_r($user_info);
echo '</pre>';


http://wiki.simplemachines.org/smf/Global_variables
"If something is wrong, fix it if you can. But train yourself not to worry: Worry never fixes anything."

Click here to view my mods for SMF

Hey 👋 Did i helped... you like what i do. You can now buy me a coffee! ☕

Kindred

well, that pulls the info on the CURRENT user...
Слaва
Украинi

Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

"Loki is not evil, although he is certainly not a force for good. Loki is... complicated."

Advertisement: