I am receiving the following error when I set the following header inside my select2 ajax. Anyone have a clue why this is happening?
Error: Refused to set unsafe header “User-Agent”
headers: {“User-Agent” : “my info here”}
I am receiving the following error when I set the following header inside my select2 ajax. Anyone have a clue why this is happening?
Error: Refused to set unsafe header “User-Agent”
headers: {“User-Agent” : “my info here”}
Apparently you’re not allowed to set that request header from a browser. A quick Google search of the error message you listed returned this: