samedi 29 février 2020

Parsing data in view layouts laravel 6

I want to make a profile photo on the admin page, this photo is in the layouts.template file, how can I get the $ profile to be sent to the layouts.template page?

@if($profil->upload!=null)
<img src=".jpg')}}" alt="..." class="avatar-img  rounded-circle">
@else
<img src="" alt="..." class="avatar-img  rounded-circle">
@endif

and i created $profil in UserController

$auth = Auth::user()->id;
$profil = Profil_user::where('user_id',$auth)->first();

how do I get my $ profile to be used in layouts.template



via Chebli Mohamed

Aucun commentaire:

Enregistrer un commentaire