Populating dropdown menu from MySQL database

Posted 10 months ago by BarbaraTackaBa

Hello everybody! I have problem with my window modal. My code is here:


Route::resource('/admin/directory','DirectoriesController'); //Directory - routes
Route::get('/admin/directory','[email protected]');


public function getDropdown()
    $genders = Gender::pluck('gender', 'id');
    $statuses = Status::pluck('status', 'id');
    return view('pages.admin.modals-admin.create.add-directory', compact('genders', 'statuses'));


  <div class="form-group">
    {{Form::select('gender', $genders,'', ['class' => 'form-control'])}}
  <div class="form-group">
    {{Form::select('status', $statuses,'', ['class' => 'form-control'])}}

It works ok but it doesn't look as it should be.. It looks like plain text... It should be modal window (form) from Bootstrap... and also other links (modals) don't work... And before adding dropdown menu looked good..

What I did wrong?

Please sign in or create an account to participate in this conversation.