0
只有一個問題。我得到一個基於cURL的代碼,它發送一個請求到serwer,然後如果響應是'有效的'它是在做一個sql查詢,但是如果響應'忙',我需要更改腳本正在使用的代理。CURL響應的數據更改PHP
我做這樣說:
$proxys = file('http_proxy.txt');
...then...
for($n = 0, $count = count($proxys); $n <= $count; $n++) {
...and to change the proxy I used something like this:
$proxy = $proxys[$n + 1];
,但它不工作。
有什麼建議嗎?
問候。
既然你已經有一個'for',在'$代理= $ proxys [$ N + 1]循環他們。 '應該是多餘的 - 你應該寫下來,以便你可以['繼續;](http://php.net/manual/en/control-structures.continue.php)代替... – DaveRandom