JSON: How do I make cross-domain JSON call

前端 未结 8 911
情歌与酒
情歌与酒 2020-11-30 06:54

I try to run the following jquery code in local Network.

 $.ajax({
     type: \"GET\",
     url: \"http://SomeSite/MyUrl/\",
     cache: false,
     data: {         


        
8条回答
  •  野性不改
    2020-11-30 07:23

    Actually you can only call GET.
    There is no failproof way to call POST,PUT,DELETE or PATCH, via cross site scripting.
    Only viable way is a hand written proxy.

提交回复
热议问题