how to get current user id in sugar 7.6?
I add some custom page in project , but i can not get session or cookie for current user.
You can get current logged user id by
Hi Jerry!In your php file you can use:
But be carefull, it doesn't work if your current user instance is not uploaded yet.
$user_id = $current_user->id;
If you want to get User ID in js file to do as:
var UserID = app.user.id;
In your php file to do as:
You can get current user Session ID to do as:
print_r($_SESSION); //will print all values in session variable.
Getting cookies to do as:
print_r($_COOKIE); // will print all values in cookies variable.
Hope this Helps..
S Ramana Raju
Retrieving data ...