THe following function is throwing error on _SPUserid
and it should be using the _spPageContextInfor.userid -- so the test must be wrong for SharePoint 2013
// 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 = _spUserId;
}
} // End of function SPServicesContext
Comments: Earl: I just tested again in a SharePoint 2013 environment and it worked fine. Can you give me some more info about what you're doing when you get the error? M.
and it should be using the _spPageContextInfor.userid -- so the test must be wrong for SharePoint 2013
// 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 = _spUserId;
}
} // End of function SPServicesContext
Comments: Earl: I just tested again in a SharePoint 2013 environment and it worked fine. Can you give me some more info about what you're doing when you get the error? M.