V
V
ViT932021-05-22 13:02:16
Nginx
ViT93, 2021-05-22 13:02:16

How to make CORS Nginx not block svg files?

Hello everyone, I add the following code to the Nginx config

location ~ \.(svg|ttf|woff2?)$ {
    add_header Access-Control-Allow-Origin *;
}


This helped with the font blocking solution, but svg files continued to be blocked as well. Tried all the solutions on the first page in google for "No 'Access-Control-Allow-Origin' svg nginx" but to no avail. ..

60a8d67d7b161403268410.png

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question