Skip to main content

Posts

Showing posts from February, 2021

SharePoint REST API QUERY

Ajax query construct $.ajax({    url: url, //THE ENDPOINT    method: "GET",    headers: { "Accept": "application/json; odata=verbose" },    success: function (data) {         console.log(data.d.results) //display result    } }); Selecting all items, all columns /_api/web/lists/getbytitle('listname')/Items?$select=*

The _spPageContextInfo

I f you are creating a SharePoint app using JavaScript and the Client side object model you need this friendly object. In the development of an app, you would require some basic properties- SharePoint as a framework provides these with the  _spPageContextInfo  object. _  spPageContextInfo  will provide these below properties:  webServerRelativeUrl  webAbsoluteUrl siteAbsoluteUrl serverRequestPath layoutsUrl webTitle webTemplate tenantAppVersion isAppWeb webLogoUrl webLanguage currentLanguage currentUICultureName currentCultureName env nid fid clientServerTimeDelta updateFormDigestPageLoaded siteClientTag crossDomainPhotosEnabled webUIVersion webPermMasks pagePersonalizationScope userId userLoginName systemUserKey alertsEnabled siteServerRelativeUrl allowSilverlightPrompt themedCssFolderUrl themedImageFileNames