php 创建文件

$myfile = fopen("newfile.txt", "w") or die("Unable to open file!");
$txt = "Bill Gates\n";
fwrite($myfile, $txt);
$txt = "Steve Jobs\n";
fwrite($myfile, $txt);
fclose($myfile);

 

posted @ 2016-10-17 17:41  一个人的孤独自白  阅读(236)  评论(0编辑  收藏  举报