Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Cross Domain Get Request in JS/JQuery

Is there a way without using a server proxy to perform a cross domain GET or POST request?

like image 415
Crothers Avatar asked Feb 03 '23 03:02

Crothers


1 Answers

If you are with only the current day browsers and have control over the external domain, you can use Cross-Origin Resource Sharing [CORS]

Most people do not have that luxury so you either have to use JSON with Padding [JSONP] or you need to use a serverside proxy.

like image 92
epascarello Avatar answered Feb 06 '23 06:02

epascarello