save files with specific name from site to disk drive
<p>here is my code is not working perfectly so what is the problem </p>

<pre><code>$urls = file('list.txt', FILE_IGNORE_NEW_LINES);
foreach($urls as $url) {
copy(trim($url),"c:/data/$url");
echo "$url is done";
ob_flush();
flush();
}       
</code></pre>

<p>some urls does not exist </p>

<p>i want that each file from url will be saved with the name of the url </p>

<p>url look like : <a href="http://site.com/index.htm" rel="nofollow">http://site.com/index.htm</a></p>
