Следующая ошибка подает мне при подаче запроса: < /p>
Access to XMLHttpRequest at 'My Server URL' from origin 'Server Name' has been
blocked by CORS policy: The 'Access-Control-Allow-Origin' header contains multiple
values 'Server Name, *', but only one is allowed.
< /code>
Однако в моем файле webapiconfig.cs я определил политику Cors следующим образом: < /p>
var cors = new EnableCorsAttribute("MyServerName", "Content-Type", "GET,PUT,POST,DELETE");
config.EnableCors(cors);
< /code>
Я определил только одно значение myservername < /em>, однако ошибка, выбрасываемая его как «имя сервера, *'< /code> < /p>
обновление: < /plorn> < /p>
. Следующая ошибка при выполнении запроса: < /p>
Access to XMLHttpRequest at 'My Server URL' from origin 'Server Name' has been
blocked by CORS policy: The value of the 'Access-Control-Allow-Origin' header in
the response must not be the wildcard '*' when the request's credentials mode is
'include'. The credentials mode of requests initiated by the XMLHttpRequest is
controlled by the withCredentials attribute.
< /code>
У меня нет Cors, определенных в моем файле web.config. < /p>
Обновление 2 < /strong> < /p>
Мое значение разрешения доступа к минимально>
Подробнее здесь: https://stackoverflow.com/questions/596 ... ever-i-onl