Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我file_get_contents()在一个循环中运行,我看到在 Apache 日志中打开了很多文件。我不知道背后的原因。file_get_contents()每次读取后是否需要关闭函数?
file_get_contents()
file_get_contents()读取文件并随后关闭文件。它返回读取的数据 or false,因此无论如何您都没有文件句柄可用于fclose()。
false
fclose()