Tag: drupal
How to access current logged in user information outside of Drupal
If you are writing PHP code in Drupal and would like to access basic user information (e.g. UID, username), you can simply define the global variable $user and get the data from there: However, it…