Copying a file with PHP Command
- by Tom
Hi, I'm having a problem using the copy function in PHP, what is wrong with it? I get the error; Parse error: syntax error, unexpected T_VARIABLE On the bottom line;
$targetDir = 'file.txt';
$targetDir2 = 'file2.txt';
copy($targetDir, $targetDir2);
Thanks
The entire file is;
<?PHP
$targetDir = 'file.txt';
$targetDir2 = 'file2.txt';
copy($targetDir, $targetDir2);
?>
copy and pasted from the doc.