您的位置:首页 > 其它

日志测试法

2016-09-05 19:55 253 查看
/**
* 写入日志
*/
function write2log($content,$filename='log') {
$myfile = fopen($filename.".txt", "a+") or die("Unable to open file!");
$txt = date('Y-m-d H:i:s')."\t".$content."\r\n";
fwrite($myfile, $txt);
fclose($myfile);
}

把内容记录在日志中,进行测试~
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: