BroChris
05-27-2004, 02:28 PM
Found this thread (http://www.codingforums.com/showthread.php?t=2276&highlight=create+file+contents) which does what I want to do, but not when the new file contains php. Is there a better way to do this? Like maybe copy a file and rename it in order to get the new file? I'm trying to do it like this right now, but it's giving me a parse error.
if($img_type!=""){
$file_name = $img_type.html;
if (!is_file($epath . '/' . $file_name')){
copy($epath . '/newevent.html', $epath . '/' . $file_name);
}
}
if($img_type!=""){
$file_name = $img_type.html;
if (!is_file($epath . '/' . $file_name')){
copy($epath . '/newevent.html', $epath . '/' . $file_name);
}
}