#14 Make E-com in Laravel 7 | Admin Details (II) | Upload Admin Image | Install Intervention Package

Published: 01 January 1970
on channel: Stack Developers
3,671
65

In Part-14 of Advance E-com Series, we will continue working on updating admin details and this time we will validate and upload admin image.

For uploading images, we will install intervention package that will help us to resize images as well.

1) Install Intervention Package :-
Simply run below composer command to install Intervention Package :-
composer require intervention/image

2) Update update_admin_details.blade.php file :-
Add enctype="multipart/form-data" in update admin details form to accept files and we will also add condition to show admin image and add another hidden field for current admin image.

3) Update updateAdminDetails function :-
Now we will update updateAdminDetails function to add validation for image and will add upload image script and finally save the image name in admins table as well.

We will create admin_photos folder under admin_images folder where we will store all admin images.

4) Update admin_sidebar.blade.php file :-
Now we will update admin sidebar with admin image who logged in. If no admin image exists then we will show some dummy image.

Thanks for watching :)


Watch video #14 Make E-com in Laravel 7 | Admin Details (II) | Upload Admin Image | Install Intervention Package online without registration, duration hours minute second in high quality. This video was added by user Stack Developers 01 January 1970, don't forget to share it with your friends and acquaintances, it has been viewed on our site 3,671 once and liked it 65 people.