SplFileObject::ftruncate
SplFileObject::ftruncate
(PHP 5 >= 5.1.0, PHP 7)
SplFileObject::ftruncate — Truncates the file to a given length
Description
public bool SplFileObject::ftruncate ( int $size )
Truncates the file to size
bytes.
Parameters
-
size
-
The size to truncate to.
Note:
If
size
is larger than the file