Last active
December 22, 2015 02:09
-
-
Save Sinetheta/6401627 to your computer and use it in GitHub Desktop.
Exposing user data through javascript on a SharePoint 2010 master page.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<%@ Register Tagprefix="SPSWC" Namespace="Microsoft.SharePoint.Portal.WebControls" Assembly="Microsoft.SharePoint.Portal, Version=14.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" %> | |
<SPSWC:ProfilePropertyLoader runat="server"/> | |
<script> | |
CurrentUser = { | |
UserName: '<SPSWC:ProfilePropertyValue PropertyName="UserName" TitleMode="true" runat="server" />', | |
FirstName: '<SPSWC:ProfilePropertyValue PropertyName="FirstName" TitleMode="true" runat="server" />', | |
Lastname: '<SPSWC:ProfilePropertyValue PropertyName="LastName" TitleMode="true" runat="server" />', | |
PictureURL: '<SPSWC:ProfilePropertyValue PropertyName="PictureURL" TitleMode="true" runat="server" />', | |
Status: '<SPSWC:ProfilePropertyValue PropertyName="SPS-StatusNotes" TitleMode="true" runat="server" />' | |
}; | |
</script> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment