Hi all. could any one show me how i can copy a remote html page to a folder inside localhost folder. For example i want to copy the following url html to folder named copy and name it to whatever value of $id is plus .html (example :23434.html) :


remote URL to copy :
PHP Code:
$copyfileurl="http://friends.myspace.com/index.cfm?fuseaction=user.viewfriends2&friendID="$id
Later i want to load the copied html to curl_setopt($curl, CURLOPT_URL, '.....html'


PHP Code:
curl_setopt($curlCURLOPT_URL'.....html');
curl_setopt($curlCURLOPT_POST0);
$result curl_exec($curl); 
I hope some one show me how this can be then.Thanks