开发者

Getting HTTP Status Code from multiple URLs using curl_multi?

开发者 https://www.devze.com 2023-02-03 08:25 出处:网络
Alright, so I\'m using curl_multi_* to connect to various sites simultaneously. How would I return the HTTP Status Code to开发者_运维技巧 a variable for comparison?You need to pass the request id thro

Alright, so I'm using curl_multi_* to connect to various sites simultaneously. How would I return the HTTP Status Code to开发者_运维技巧 a variable for comparison?


You need to pass the request id through curl_getinfo and you'll get back an array containing a key of http_code.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号