Loading…

How to pass multiple variables by controller to blade file?

$valiable1 = 'Best';

$valiable2 = 'Interview';

$valiable3 = 'Question';

return view('frontend.index', compact('valiable1', valiable2', valiable3'));

In you View File use can display by {{ $valiable1 }} or {{ $valiable2 }} or {{ $valiable3 }}

Suggest An Answer

No suggestions avaliable!

Latest post from Laravel Interview Questions

Ask Question