Source string

  • To display the name of a registered user, use this instead:

    global $user;
    if ($user->uid) {
      print t('Welcome @name! Thank you for visiting.', array('@name' => format_username($user)));
    }
    else {
      print t('Welcome visitor! Thank you for visiting.');
    }
    

Used at the following places