New Properties in spPageContextInfo in SharePoint Online/Office 365

Hi All,

Today, sharing some important finding. In our SP2013 farm solution project we were very heavily using Java Script variable _spPageContextInfo which SharePoint providing us. There are various good blog post for this, one of those is:

Using _spPageContextInfo to Determine the Current SharePoint Context in Script.

So I will not go into more details of it.

But recently I got a chance to use this variable with my SharePoint online site. Then I noticed there are few more properties which are available in SharePoint Online.

One of the important value userLoginName: In on premise version this property of _ spPageContextInfo is not available but available in SharePoint online. This seems to be very useful property since without extra call (and callbackJ) we directly get the user LogInName.

Couple of the other important properties are like isAppWeb, env etc. but I’ll explore those and may be write new post.

Thanks!