Welcome! Log In Create A New Profile

Advanced

Re: Access to XMLHttpRequest has been blocked by CORS policy: No ‘Access-Control-Allow-Origin’ header is present on the requested resource.

All files from this thread

File Name File Size   Posted by Date  
reactjsnginx.conf 2.7 KB open | download kaushalshriyan 05/28/2020 Read message
drupalcmsnginx.conf 2 KB open | download kaushalshriyan 05/28/2020 Read message
Francis Daly
May 28, 2020 08:42AM
On Thu, May 28, 2020 at 12:50:34PM +0530, Kaushal Shriyan wrote:

Hi there,

> Access to XMLHttpRequest at ‘
> > https://tmobilereactdrupal.mydomain.com:8080/oauth/token’ from origin ‘
> > https://tmobilereactdrupal.mydomain.com’ has been blocked by CORS policy:
> > No ‘Access-Control-Allow-Origin’ header is present on the requested
> > resource.

In your "drupal" nginx config, if the request is handled in the "php"
location, there is no Access-Control-Allow-Origin header added.

You might want the "add_header" line there instead.

Good luck with it,

f
--
Francis Daly francis@daoine.org
_______________________________________________
nginx mailing list
nginx@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx
Subject Author Posted

Access to XMLHttpRequest has been blocked by CORS policy: No ‘Access-Control-Allow-Origin’ header is present on the requested resource. Attachments

kaushalshriyan May 28, 2020 03:22AM

Re: Access to XMLHttpRequest has been blocked by CORS policy: No ‘Access-Control-Allow-Origin’ header is present on the requested resource.

Francis Daly May 28, 2020 08:42AM

Re: Access to XMLHttpRequest has been blocked by CORS policy: No ‘Access-Control-Allow-Origin’ header is present on the requested resource.

Sam Henaghan May 28, 2020 08:44AM

Re: Access to XMLHttpRequest has been blocked by CORS policy: No ‘Access-Control-Allow-Origin’ header is present on the requested resource.

kaushalshriyan May 28, 2020 10:48AM

Re: Access to XMLHttpRequest has been blocked by CORS policy: No ‘Access-Control-Allow-Origin’ header is present on the requested resource.

Francis Daly May 28, 2020 07:24PM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 129
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 500 on July 15, 2024
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready