curl_multi_exec()

2019-06-25 05:15发布

问题:

I dont understand the PHP cURL function curl_multi_exec().

int curl_multi_exec(handle h, int running)

I went through the PHP manual http://www.php.net but don't understand what the variable running does.

Searched a lot on Google but didn't find the explanation. Can somebody explain?

回答1:

Every time you call it, that variable is assigned to tell you whether the op is still running:

curl_multi_exec($ch, $running);

After that, $running is non-zero if the operations are still running. If so, you will have to call it again (normally in a loop).



标签: php libcurl