note 93245 modified in function.copy by danbrown
| From: | danbrown@php.net | Date: | Sun, 30 Aug 2009 18:49:50 +0000 |
| Subject: | note 93245 modified in function.copy by danbrown | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-160054@lists.php.net to get a copy of this message | ||
some hosts disable copy() function and say its for security
and for some copy is important so this is and simple function that do same as copy function effect
how smart php can help us l like php
<?php
function copyemz($file1,$file2){
$contentx =@file_get_contents($file1);
$openedfile = fopen($file2, "w");
fwrite($openedfile, $contentx);
fclose($openedfile);
if ($contentx === FALSE) {
$status=false;
}else $status=true;
return $status;
}
?>
--was--
some hosts disable copy() function and say its for security
and for some copy is important so this is and simple function that do same as copy function effect
how smart php can help us l like php
function copyemz($file1,$file2){
$contentx =@file_get_contents($file1);
$openedfile = fopen($file2, "w");
fwrite($openedfile, $contentx);
fclose($openedfile);
if ($contentx === FALSE) {
$status=false;
}else $status=true;
return $status;
}
http://php.net/manual/en/function.copy.php