Download the PHP package hector-del-rio/yii2-image-up without Composer
On this page you can find all versions of the php package hector-del-rio/yii2-image-up. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Informations about the package yii2-image-up
yii2-image-up
Simple and responsive image upload and preview for yii2 models using yii2-upload-behavior extension.
When using this extension in your an image preview of the specified attribute will be shown along with a button to change it. When a new image is selected, the preview will show the new image.
Installation
The preferred way to install this extension is through composer.
Either run
or add
to the require section of your composer.json
file.
Requirements
This extension builds up on top of yii-dream-team/yii2-upload-behavior's class ImageUploadBehavior. You must follow the instructions on how to use this module, which can be found here.
Usage
In your view:
Options
The following options are available to configure:
- thumbsEnabled: whether thumbs should be shown instead of original size images. The widget will enable thumbs only if they can be found.
- thumbProfileName: the thumb profile name as specified in configuration. Defaults to "thumb".
- options: the options to be passed to the function. [More info can be found here](http://www.yiiframework.com/doc-2.0/yii-helpers-basehtml.html#activeFileInput()-detail)
- previewOptions: the options to be passed to the function. [More info can be found here](http://www.yiiframework.com/doc-2.0/yii-helpers-basehtml.html#img()-detail)