Skip to content

ravikoriya07/package-upload

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 

Repository files navigation

package-Fileupload

A package for convenient way to upload files to the different storages

Latest Version Issues Stars Total Downloads

Installation

  1. Run the command below to add this package:
composer require xpert/upload
  1. Open your config/app.php and add the following to the providers array:
Xpert\upload\UploadServiceProvider::class
  1. Open your config/app.php and add the following to the aliases array:
'FileUpload' => Xpert\upload\Facade\FileuploadFacade::class
  1. Run the command below to publish the package:
php artisan vendor:publish

Usage Controller

To upload file:

use FileUpload;
public function upload(Request $request)
{   
    // This will upload your file to the upload package composer
    FileUpload::upload($request,'uploads/images','img');

}

package-FileuploadResize

A package for convenient way to upload files to Resize original file and thumbnail

Installation

  1. Run the command below to add this package:
composer require intervention/image
  1. Open your config/app.php and add the following to the providers array:
Intervention\Image\ImageServiceProvider::class
  1. Open your config/app.php and add the following to the aliases array:
'ImageResize' => Intervention\Image\Facades\Image::class
  1. Run the command below to publish the package:
php artisan vendor:publish

Usage Controller

To upload file:

use FileUpload;
public function uploadWithResize(Request $request)
{   
    // This will upload your file to the resize upload.
    FileUpload::uploadResize($request,'uploads/original','uploads/thumbnail','image');

}

About

this package used for upload image

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages