I'm trying to access the logged in Umbraco User, not member, but I cant get it work.
I have tried with the following methods but none work, they all return null:
umbraco.BusinessLogic.User.GetCurrent()
UmbracoContext.UmbracoUser
UmbracoContext.Security.CurrentUser
umbraco.helper.GetCurrentUmbracoUser()
I can access the user, for example Name, with the code below:
UmbracoContext.Application.Services.UserService.GetByEmail("[email protected]").Name
I have tried this code being logged in as a user and member, only user, only member and not logged in at all and it always returns the same result, null.
I have tried the code in a SurfaceController and UmbracoApiController with the same result. There is no problem getting the logged in member with Membership.GetUser();
Has anyone else experienced this?
Using: Umbraco version 7.3.5 assembly: 1.0.5858.25602