PHP code example of ligne / file-move
1. Go to this page and download the library: Download ligne/file-move library. Choose the download type require. 2. Extract the ZIP file and open the index.php. 3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
ligne / file-move example snippets
use Ligne\FileMove;
$file = new FileMove("myfile","files/"); //The final slash is
$file->setFileName();
/**
* The mime type of the file, if the browser provided this information.
* An example would be "image/gif".
* This mime type is however not checked on the PHP side and therefore don't take its value for granted.
*/
$file->getFileType();
$file->debugData();
$file->getDirToSave();
$file->getExtension();
$file->getExtensionFromName();
$file->getFileName();
$file->getInputFileName();