PHP Classes

PHP File Manipulation Class: Manipulate files and directories in several ways

Recommend this page to a friend!
     
  Info   View files Files   Install with Composer Install with Composer   Download Download   Reputation   Support forum   Blog    
Ratings Unique User Downloads Download Rankings
StarStarStarStar 64%Total: 350 All time: 6,996 This week: 488Up
Version License PHP version Categories
php-files-manipulati 3.5MIT/X Consortium ...5.6PHP 5, Files and Folders
Description 

Author

This package can manipulate files and directories in several ways.

It can perform several types of operations. Currently it can:

- Create directories
- Generate random text strings
- Change file permissions
- Copy files or folders
- Move files and folders
- Delete files and folders
- Upload files validating several parameters
- Read and write files
- Setting default directory and sub directory

Picture of Muhammad Umer Farooq
Name: Muhammad Umer Farooq is available for providing paid consulting. Contact Muhammad Umer Farooq .
Classes: 52 packages by
Country: Pakistan Pakistan
Age: 23
All time rank: 84310 in Pakistan Pakistan
Week rank: 26 Up1 in Pakistan Pakistan Up
Innovation award
Innovation award
Nominee: 6x

Recommendations

file php class pdo
I need manipulate files

Details

PHP Files Class

This package can manipulate files and directories in several ways.

This package can manipulate files and directories in several ways.

It can perform several types of operations. Currently it can:

  1. Create directory
  2. Generate random string
  3. Change file permission
  4. Copy Files or folders
  5. Move files and folders
  6. Delete files and folders
  7. Upload files with validation
  8. Multiple file upload with validation
  9. read/write files ## Requirement
  • PHP
  • Composer

install

run this command


## usage

<?php

use Lablnet\Files;

require_once "../vendor/autoload.php";

$files = new Files();

//Write on file $files->open('test.txt','writeOnly')->write("I am test files");

// read the file var_dump($files->open('test.txt','readOnly')->read('test.txt'));

//delete the file $files->delete('test.txt');

//Make dir $files->mkDir('name');

//Change premission $files->permission('test.txt',0774);

//Delete files $files->deleteFiles(['test.txt']);

//Copy files $files->copyFiles('/name','dir/',['test.txt']);

//Move files $files->moveFiles('/','dir/',['test.txt']);

//Delete dirs $files->deleteDirs(['test.txt']);

//Copy dirs $files->copyDirs('/','dir/',['test.txt']);

//Move dirs $files->moveDirs('/','dir/',['test.txt']);

//File upload $status = $files->fileUpload($_FILES['file'],'/','image'); var_dump($status);

//Multiple file upload $status = $files->filesUpload($_FILES['file'],'/','image',count($_FILES['file']['name'])); var_dump($status);


  Files folder image Files (7)  
File Role Description
Files folder imageexample (2 files)
Files folder imagesrc (1 file)
Accessible without login Plain text file .travis.yml Data Auxiliary data
Accessible without login Plain text file composer.json Data Auxiliary data
Accessible without login Plain text file LICENSE Lic. License text
Accessible without login Plain text file README.md Doc. Documentation

  Files folder image Files (7)  /  example  
File Role Description
  Accessible without login Plain text file index.php Example Example script
  Accessible without login Plain text file index2.php Example Example script

  Files folder image Files (7)  /  src  
File Role Description
  Plain text file Files.php Class Class source

The PHP Classes site has supported package installation using the Composer tool since 2013, as you may verify by reading this instructions page.
Install with Composer Install with Composer
 Version Control Unique User Downloads Download Rankings  
 100%
Total:350
This week:0
All time:6,996
This week:488Up
 User Ratings  
 
 All time
Utility:83%StarStarStarStarStar
Consistency:83%StarStarStarStarStar
Documentation:75%StarStarStarStar
Examples:75%StarStarStarStar
Tests:-
Videos:-
Overall:64%StarStarStarStar
Rank:663