Class: f
This class makes it easy to
create/edit/delete files
Methods
-
f::append
Appends new content to an existing file
-
f::convert
Convert the filename to a new extension
-
f::dirname
Just an alternative for dirname() to stay consistent
-
f::extension
Gets the extension of a file
-
f::filename
Extracts the filename from a file path
-
f::move
Moves a file to a new location
-
f::name
Extracts the name from a file path or filename without extension
-
f::nice_size
Converts an integer size into a human readable format
-
f::read
Reads the content of a file
-
f::remove
Deletes a file
-
f::safe_name
Sanitize a filename to strip unwanted special characters
-
f::size
Returns the size of a file.
-
f::write
Creates a new file