Download the PHP package monim67/laravel-user-image-croppie without Composer

On this page you can find all versions of the php package monim67/laravel-user-image-croppie. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package laravel-user-image-croppie

laravel-user-image-croppie

This package adds square/circular user profile image with an update event to laravel application. Users can rotate, resize and crop profile picture before upload with pure JavaScript, no jQuery needed. An avatar controller is included to handle image upload which emits an event after a successful avatar upload.

Steps of image upload - laravel-user-image-croppie

version of laravel-user-image-croppie licence of laravel-user-image-croppie

Features

Getting Started

Install the package via composer and publish the config file.

composer require monim67/laravel-user-image-croppie
php artisan vendor:publish --provider="Monim67\LaravelUserImageCroppie\ServiceProvider" --tag=config

If you already have a database column for user's image, you need to specify it in the config file, otherwise you can publish the migration from this package that adds a column named avatar to users table.

php artisan vendor:publish --provider="Monim67\LaravelUserImageCroppie\ServiceProvider" --tag=migrations
php artisan migrate

Add the following to your routes in web.php file.

This will include edit and update routes for user image. You can use any prefix of your choice.

If you only want the update route, use the following instead.

The edit route will look for resources\views\avatar\edit.blade.php. So create a file extending your base layout template and include the image upload form in it.

That is all you need, the controller is shipped with the package, you don't need to write controller actions. Run the development server and visit http://localhost:8000/avatar/edit to see it in action.

Customizing the options

You can edit the config file lui-croppie.php in your config directory to customize the options to your needs.

NOTE: For circular profile picture set image type to circle.

Other Form Layouts

At present only Bootstrap 3 layout is included, few more will be added later. You can also draw your own layout, or even create PR with your own layout.

If you don't want a separate page to upload image, you can add this form to one of your existing pages ie the profile page or account settings page. Then include only update route to your web.php and include the password-update form in the page of your choice.

Localization

If you want to customize package language files publish them to modify. Files will be published to resources\lang\vendor\lui-croppie directory. You can create lang files for other languages there.

php artisan vendor:publish --provider="Monim67\LaravelUserImageCroppie\ServiceProvider" --tag=lang

User Image Update Event

When user uploads an image Monim67\LaravelUserImageCroppie\Events\AvatarUpdate event is emitted, you can subscribe to the event or add listeners to it.

Acknowledgments

This package uses Croppie Javascript Image Cropper to crop images to upload.


All versions of laravel-user-image-croppie with dependencies

PHP Build Version
Package Version
Requires laravel/framework Version ^5.5
intervention/image Version ^2.4
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package monim67/laravel-user-image-croppie contains the following files

Loading the files please wait ....