fclose

PHP 4, PHP 5, PHP 7, PHP 8
fclose - Closes an open file pointer
Manual
Code Examples

fclose( resource$stream ): bool

The file pointed to by stream is closed.

Parameters

stream

The file pointer must be valid, and must point to a file successfully opened by fopen or fsockopen.

Return Values

Returns true on success or false on failure.

Related Functions

Example of fclose

Show all examples for fclose

PHP Version: