PHP中file_put_contents
2020.11.16 | 1958閱讀 | 0條評(píng)論 | php
換行: PHP_EOL
追加:FILE_APPEND
file_put_contents("log.txt", "Hello world everyone.".PHP_EOL, FILE_APPEND);
寫入數(shù)組:
$arr = array();
$str = var_export($arr,TRUE);
file_put_contents($filename,$str);
發(fā)表評(píng)論