Elfyn, your code is not working. Apparently, it cannot be done with require(), at least not the way you suggest.
Here is the code I am using, which works:
<?php
$target = "c:path/to/file/";
$fetch = "http://www.server.com";
$fp1 = file($fetch, "r");
if (!$fetch)
{print "Ooops! Couldn't find the page!"; die;}
else
{
$content = join("", $fp1);
$fp2 = fopen($target, "w");
fwrite($fp2, $content);
}
$msg++;
}
print "done!";
?>