Yii2 Lesson - 17 Uploading Files to the server

preview_player
Показать описание
Thanks for watching this yii video tutorial. Uploading Files to the server.

Share this if you like it :)
Happy Hunting Yii developers
Рекомендации по теме
Комментарии
Автор

Hello, i've tried but the path of the uploaded file did not inserted in my database in the logo column.

yanieautumn
Автор

And to show the image thumbnail in the index.php, add this to index.php at the GridView:
[
'attribute'=>'logo',
'value'=>'logo',
'format' => ['image', ['width'=>'10', 'height'=>'10']]
],

HuyPham-jwwo
Автор

You have really helped me to understand Yii. thanks for your great work

amwolloamwollo
Автор

thank you! I've been looking for this solution for a long time

НинаРадионова-ъь
Автор

Hi, to show the image in the view.php file, simply add this code:
'logo:image',

HuyPham-jwwo
Автор

Man, keep it going! u helped me so much!

dve
Автор

Where I have to upload to get access for this image from both frontend and backend?

AlexSolomaha
Автор

thanks a lot, its helpful new yii beginner including me, thats great tutorial

path
Автор

Thanks for another excellent and practical tutorial. 
My first question is there an elegant way for Yii 2 to handle upload of a large file that may take longer than request process time on a sheared server ? In .NET I would use asynchronous processing to keep the client from timing out.

I would love see a update to this tutorial showing how this would be done in Yii 2.

dwbyfield
Автор

Great Tutorials, but only One suggestion that Please share the code of every tutorial somewhere on your blog/website or anywhere from where we can copy and practice the code.

ankitkapoor
Автор

Plz help me I am getting this error. finfo_file(/tmp/php4QQ5g3): failed to open stream: No such file or directory

Chiragpanchal
Автор

Hello the error is for ? failed to open stream: No such file or directory tks

djskarlata
Автор

hy bro it just working and yes thank also for nyc explanation

fejanmalek
Автор

Thank you very very much!
You are the best!

student
Автор

It's great. And what about the creation thumbnails on the fly, resize and crop? Please :)

rosolovsky
Автор

Hi, I'm following the tuturials, this it works fine. Can u add how display and resize the image file in the view ? Thanks

guillermoromano
Автор

i want to upload image to database but the image just stored in folder and not saved in database. i dont understand what is the problem, please help me,

anmolacharya
Автор

Sir  How can we download file  if once i have uploaded through backend/form . it is successfully uploded but i don know how can v download....plz guide...

Your tutorial are very usefull for yii2 u very much.

vivdroid
Автор

Thx for tutorial.
I use this tutorial for profile page (amnah/yii2-user) and get "Call to a member function saveAs() on null", after put saveAs inside "if" error gone, but every profile update (nickname change for example) make new link inside db - without "/images" and extension. After add "save the path in the DB column" string inside if - all become works fine: if($model->file !== null)
{

// save the path in the DB column
$model->logo =
}

Freeshnik
Автор

Hi, this video very use full and also work in my system....

SanthoshKumar-phvu