Version Information Build version : v1.0.0 Date Of Build :
Open File Handler (OFH) is a standalone File and Directory Handling Library, OFH is designed to control and cominicate with the Server file structure, set permissions and manage files and directories.
As Part of the newly designed Open File Handler library it will now incorperate the use of the lazarusphp FileWriter Library giving more control relating to files and folders.
Along side the FileWriter and File handler the Library will also feature a permissions manager. The Permissions manager will give the FileHandler library the ability to set permissions relating to the files and directories.
- Src
- Traits Permissions.php Structure.php
- CoreFiles
- FileWriterCore.php
- FileHandlerCore.php
- Interfaces
- FileWriterInterface.php
- FileHandlerInterface.php
- PermissionsInterface.php
- StructureInterface.php
- FileWriter.php
- FileHandler.php
Installation
composer install lazarusphp/openfilehandler
Generating a root Directory (optional)
FileHandler::generateRoot($pathname);
// Using Object orientated based can also be done like so, this will also Handle Generate Root.
$filehandler = new FileHandler($pathname);Creating a Directory
if a root is not generated but required, the root directory will have to be passed for the following methods.
// Make Sure path exists
FileHandler::createDirectory("/Apps/Login");Listing Files and Folders
FileHandler::listAll("/Apps");Deleting Directory and files
FileHandler::deleteDirectory("/Apps");