Forum Discussion
Devanandrk
Dec 10, 2018Copper Contributor
SharePoint frameworks
Is there any suggestions on retrieving current site page title using Page context object rather going with API
- Dec 10, 2018Oh PAGE TITLE :) then I do not think another way than using API for now.
Thuyavan Ganesan
Dec 10, 2018Iron Contributor
If I understand correctly, you want to retrieve host page right ?
Contextual information for the SharePoint site ("SPWeb") that is hosting the page.
your page tile is going to be same under the site...
Please refer this let me know.
https://docs.microsoft.com/en-us/javascript/api/sp-page-context/pagecontext?view=sp-typescript-latest
Contextual information for the SharePoint site ("SPWeb") that is hosting the page.
your page tile is going to be same under the site...
Please refer this let me know.
https://docs.microsoft.com/en-us/javascript/api/sp-page-context/pagecontext?view=sp-typescript-latest
- DevanandrkDec 10, 2018Copper Contributor
yes i can agree to take this for retrieving current site title or site related details etc, but the required thing is need to take current site page Title.
Under Site contents > Under Site Page > Create a site page and need to check for displaying the site page title with respect to page context than going with API
- Thuyavan GanesanDec 10, 2018Iron ContributorOh PAGE TITLE :) then I do not think another way than using API for now.
- DevanandrkDec 10, 2018Copper Contributorthanks for the response! Hope you are aware of SPFX webpart
How to clear this CORS error as follows
"Access to XMLHttpRequest at 'https://centralindia0-completenessp.svc.ms/api/collection' from origin 'https://avasoft992.sharepoint.com' has been blocked by CORS policy: No 'Access-Control-Allow-Origin' header is present on the requested resource."
Thanks in advance!