I'm making a Chrome plugin that calls a PHP script on my server, but I keep getting the "No 'Access-Control-Allow-Origin' header is present on the requested resource." error.
I have added the header settings in my Nginx config, so I have no idea what else could be the problem.
location / {
add_header 'Access-Control-Allow-Origin' '*';
add_header 'Access-Control-Allow-Credentials' 'true';
add_header 'Access-Control-Allow-Methods' 'GET';
try_files $uri $uri/ /index.html;
}
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With