「PHP Programming/Files」の版間の差分

(→‎Line-endings: clarify line endings)
Opening and closing the file is all well and good but to perform useful operations you need to know about [http://php.net/fread fread()] and [http://php.net/fwrite fwrite()].
When a PHP script finishes executing, all open files are automatically closed. So although it is not strictly necessary to close a file after opening it, it is considered good programming practice to do so.