Click here to Skip to main content
15,891,529 members
Please Sign up or sign in to vote.
5.00/5 (1 vote)
See more:
How to set "Access-Control-Allow-Origin: *" header in jquery
Posted

1 solution

It's not about 'How' you do something but 'Why' you do is important.

Access-Control-Allow-Origin header is used by the server to tell the browser if the CORS [^](Cross-Origin Resource Sharing) is allowed or not.

Thus, you don't set it from the client but your web server needs to add it in the response.

By the way, here is nice article on CORS.

http://www.html5rocks.com/en/tutorials/cors/[^]
 
Share this answer
 
v2

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900