Hi Guys I want to create a script so when the link for the following script the following php script is executed. I need to make it replace the index.html with $filetocopy
At the moment all it does is copy the actual text where instead I want it to read aaaaaaaatemplate.htm and this content to replace the index.html coding..
Can anyone help me pls?
Joe
<?
$TheFile = "/home/j/jcthr/www/template/index.html";
$filetocopy = "/home/j/jcthr/www/template/aaaaaaaatemplate.htm";
$Open = fopen($TheFile, "w+");
if ($Open) {
fwrite ($Open, $filetocopy);
fclose ($Open);
$Worked = TRUE;
echo ("succesfuly");
} else {
$Worked = FALSE;
}
return $Worked;
?>