I have a simple drop-down in a form.
The form is:
{{Form::label('language', 'Language')}}
{{Form::select('Language', $language, '', ['class'=>'form-control']) }}
In the view function in the controller the array is:
$languages = ['English', 'French'];
The store function in the controller is:
$language = $request->input('language');
The method, however, stores the position of the values instead of the value itself. So, if I do a dd(request()->all());, I get:
array:4 [▼
"_token" => "..."
"title" => "Course"
"Language" => "1"]
How can I get the values instead of the position?