| 
	
 | 
 Posted by macca on 09/26/07 00:19 
<?php 
 
// Generate a name based on the date e.g. "log_26_9_2007.txt" 
$log_name = "log_".date("j_n_Y").".txt"; 
 
// Open log for writing and create if does not exist 
$open_log = fopen($log_name, "a+"); 
 
$funz = funz1(); 
 
fwrite($open_log, $funz); 
 
fwrite($open_log, "\n"); 
 
// second param gives print_r a return value so it can be written to 
the log 
fwrite($open_log, print_r(XXXXX, TRUE)); 
 
fclose($open_log); 
 
?>
 
  
Navigation:
[Reply to this message] 
 |