yii2-file-upload-widget icon indicating copy to clipboard operation
yii2-file-upload-widget copied to clipboard

Please update blueimp-file-upload depenendcy

Open gb5256 opened this issue 5 years ago • 9 comments

There is a bug in versions below 10 which does not allow certain images to be uploaded. See this: https://github.com/blueimp/jQuery-File-Upload/issues/3639 Is it possible that you update your dependency? You are using 9.x right now.

Thanks ! Gb5256

gb5256 avatar May 04 '20 16:05 gb5256

Hi @gb5256 I have the same problem, any suggestion to solve until they fix? Thank's

FedericoBenedetti1976 avatar Sep 28 '20 07:09 FedericoBenedetti1976

Hi, that is a looong time ago... :-) If I remember correctly, then this had nothing to with 2amigos, but with a dependency in the blueimp-bower assets. To my knowledget there was an update of blueimp which has solved it. So please try to "composer update" and see if it solves it for you as well.

gb5256 avatar Sep 28 '20 07:09 gb5256

thank's for fast reply. That was one of my first way that i try to solve this problem. I delete all "vendor" directory and run "composer update", but i have still the problem. I think thant i must change widget or simply use directly jquery blueimp without any extension.

FedericoBenedetti1976 avatar Sep 28 '20 07:09 FedericoBenedetti1976

I think thant i must change widget or simply use directly jquery blueimp without any extension.

The easiest (but not so professional) workaround is to replace in your project: vendor/bower-asset/blueimp-load-image/load-image.all.min.js with old version: https://raw.githubusercontent.com/blueimp/JavaScript-Load-Image/v4.0.1/js/load-image.all.min.js

Keep this file handy in case composer replace it back.

ffurbo avatar Sep 29 '20 19:09 ffurbo

I think thant i must change widget or simply use directly jquery blueimp without any extension.

The easiest (but not so professional) workaround is to replace in your project: vendor/bower-asset/blueimp-load-image/load-image.all.min.js with old version: https://raw.githubusercontent.com/blueimp/JavaScript-Load-Image/v4.0.1/js/load-image.all.min.js

Keep this file handy in case composer replace it back.

Hi. I made a fork and pointed out the necessary dependencies. You can use it to avoid copying the file all the time. - https://github.com/reinq/yii2-file-upload-widget

reinq avatar Oct 26 '20 18:10 reinq

I think thant i must change widget or simply use directly jquery blueimp without any extension.

The easiest (but not so professional) workaround is to replace in your project: vendor/bower-asset/blueimp-load-image/load-image.all.min.js with old version: https://raw.githubusercontent.com/blueimp/JavaScript-Load-Image/v4.0.1/js/load-image.all.min.js Keep this file handy in case composer replace it back.

Hi. I made a fork and pointed out the necessary dependencies. You can use it to avoid copying the file all the time. - https://github.com/reinq/yii2-file-upload-widget

hi @reinq how to replace your fork on existing "2amigos/yii2-file-upload-widget": "~1.0" ?

FedericoBenedetti1976 avatar Dec 07 '20 10:12 FedericoBenedetti1976

I recommend leaving this plugin, but if you have legacy project (just like me), I found simple solution just add 'disableExif' => true to clientOptions while rendering widget

Example

FileUploadUI::widget([
            'model' => $model,
            'attribute' => $attribute,
            'url' => $url,
            'clientOptions' => [
                'disableExif' => true,
            ],
        ])

kcioch avatar Apr 20 '21 08:04 kcioch

Hello from 2021 :)

Solution that worked for me:

  • Copy https://raw.githubusercontent.com/blueimp/JavaScript-Load-Image/v4.0.1/js/load-image.all.min.js to sources directory
  • Using the AssetManager, replace the default Asset with something like this:
use dosamigos\fileupload\BlueimpLoadImageAsset;

Yii::$app->assetManager->bundles[BlueimpLoadImageAsset::class] = [
    'sourcePath' => __DIR__ . '/assets/source' // load-image.all.min.js directory
];
  • that's all :)

gebekov avatar Jun 08 '21 17:06 gebekov

I think thant i must change widget or simply use directly jquery blueimp without any extension.

The easiest (but not so professional) workaround is to replace in your project: vendor/bower-asset/blueimp-load-image/load-image.all.min.js with old version: https://raw.githubusercontent.com/blueimp/JavaScript-Load-Image/v4.0.1/js/load-image.all.min.js

Keep this file handy in case composer replace it back.

This is the only solution that worked for me so far. Thanks

cosmicwebsrl avatar Jun 15 '21 10:06 cosmicwebsrl