Anything wrong with my cURL code (http status of 0)?

前端 未结 5 934
半阙折子戏
半阙折子戏 2020-12-30 12:11

Consistently getting a status of 0 even though if I copy and paste the url sent into my browser, I get a json object right back



        
5条回答
  •  囚心锁ツ
    2020-12-30 12:39

    FYI, you can also get a status code of 0 if the curl connection times out before the remote server returns data. In that case you need to set curl time out options to avoid that situation. Just posting this for anyone else having status 0 problems.

提交回复
热议问题