{% else-1 %}
Проверял на хосте, 20 метровый файл скачался в момент, размер файла ограничивается памятью сервера *

                        
<?php

$url = 'http://compolom.ru/222.jpg';
$path = '222.jpg';

$ch = curl_init();
$fp = fopen($path, "w+");

curl_setopt($ch, CURLOPT_URL, $url);
curl_setopt($ch, CURLOPT_FAILONERROR, false);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($ch, CURLOPT_TIMEOUT, 60);
curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);
curl_setopt($ch, CURLOPT_HEADER, false);
curl_setopt($ch, CURLOPT_FILE, $fp);

curl_exec($ch);

curl_close($ch);
fclose($fp);

?>
0 29 0
0

Нет фото
burneds * 0.04
• 7 дек 2014, 20:21


еще можно в putty wget http://domain.ru/file .avi или указать все урл сразу wget -i file.txt это избавит от постояного прописывания адреса в коде