I have this problem, I can't find the way to add class attribute in this Dropdown box
{{Form::select('bancada', Bancada::lists('nombre','idBancada'))}}
I have tried various syntax, but can not get it to work.
Any suggestions? Thanks
Use the forth parameter to add attributes to your element.
{{Form::select('bancada', Bancada::lists('nombre','idBancada'), null, ['class' => 'my_class'])}}
Take a look at the source ($options
is the same as attributes for your element).
{{ Form::select('status', $statusList, null, array('class' => 'form-control')) }}
In above example you can add class as fourth parameter
来源:https://stackoverflow.com/questions/26831509/add-class-to-select-element-on-laravel