Using ajax to make a curl request

前端 未结 3 367
逝去的感伤
逝去的感伤 2021-01-25 05:51

This answer has helped me largely but hasn\'t fully resolved my issues. I\'m using code similar to that, which is:

function getResponse() {

    var the_url = \"         


        
3条回答
  •  不思量自难忘°
    2021-01-25 06:39

    If you were using simple AJAX, then you could just add custom (basic authentication) header at the begining of your AJAX call. But you are using JSONP, which actually is equivalent to adding

提交回复
热议问题