Get user_id of currently logged-in user
-
How can I get the user_id of the logged-in user, not the user of the profile page you are viewing?
I know um_profile_id() or um_user(‘ID’) can give you the latter per this page.
https://docs.ultimatemember.com/article/124-umprofileidWhat I want to achieve is, when you have the same template for all profile pages, if you are viewing your own profile page (you can either visit from members grid or directly from mypage) you show certain content to the logged-in user only. And this will not be shown if you are viewing some other user’s profile.
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
- The topic ‘Get user_id of currently logged-in user’ is closed to new replies.