function SPServicesContext() {
// SharePoint 2010 gives us a context variable
if(typeof _spPageContextInfo !== "undefined") {
this.thisSite = _spPageContextInfo.webServerRelativeUrl;
this.thisList = _spPageContextInfo.pageListId;
this.thisUserId = _spPageContextInfo.userId;
// In SharePoint 2007, we know the UserID only
} else {
this.thisSite = "";
this.thisList = "";
this.thisUserId = (typeof _spUserId !== "undefined") ? _spUserId : undefined;
}
↧
New Post: "_spUserId is undefined" error when including the ALPHA
↧