S
shapper
Hello,
I know that only authenticated users has a UserName. In Anonymous
users there is an ID.
If I am not wrong when getting a profile of a user, if the user is
authenticated the UserName is used. If it is anonymous it is used its
ID that is also stored on a cookie.
What is the correct way to get the UserName or Anonymous user ID of
the current user?
I am using:
HttpContext.Current.Profile.UserName
Is this the correct way?
Thanks,
Miguel
I know that only authenticated users has a UserName. In Anonymous
users there is an ID.
If I am not wrong when getting a profile of a user, if the user is
authenticated the UserName is used. If it is anonymous it is used its
ID that is also stored on a cookie.
What is the correct way to get the UserName or Anonymous user ID of
the current user?
I am using:
HttpContext.Current.Profile.UserName
Is this the correct way?
Thanks,
Miguel