New answers tagged


Using below methods you will get SPHostUrl and SPAppWebUrl. In hostweb you will get your "" url. // read URL parameters function getQueryStringParameter(param) { var params = document.URL.split("?")[1].split("&"); var strParams = ""; for (var i = 0; i < params.length; i = i + 1) { var singleParam = ...


SP.PageContextInfo.get_siteAbsoluteUrl(), will give you the Site Collection URL. SP.PageContextInfo.get_webAbsoluteUrl(), will give you the Site (or subsite) URL.


The only tricky part for accessing SharePoint Online from the Client Object Model will be the authentication. There is no direct method of authenticating with SharePoint Online from the CSOM so Microsoft has released a work around. You can find the details and code here: ...

Top 50 recent answers are included