You need to sign in to do that
Don't have an account?
S R 30
AJAX Call from Lightning Component
Hi, I'm trying to make AJAX call to the REST API Endpoint directly from Lightning Component.
I see following error:
Cross-Origin Request Blocked: The Same Origin Policy disallows reading the remote resource at Endpoint. (Reason: CORS header ‘Access-Control-Allow-Origin’ missing).
Please help me to understand this error.
Ajax calls with Lightning Components May I request you please refer the below link for reference.
- http://www.rattanpal.com/2017/09/03/salesforce-make-ajax-calls-lightning-components/
- https://developer.salesforce.com/docs/atlas.en-us.lightning.meta/lightning/js_api_calls_platform.htm
Hope it helps.Please mark it as best answer if the information is informative.so that question is removed from an unanswered question and appear as a proper solution.
Thanks
Rahul Kumar