franklin franklin - 1 year ago 122
CSS Question

How to implement css classes in form using laravel collective 5.2 . *

Hi I am developing an application and I need to implement css classes to a form using collective laravel "5.2.*".

The code I have for now is this:

{!! Form::model($user, array('route' => array('home.user.update', $user->id)), css clases should go here? or what !!}

{!! Form::close() !!}

When I try to put css class, it doesn't work.

Answer Source

Class should added like this..

 {!! Form::model($home, ['id' => 'form1','method' => 'PATCH', 'action' => ['HomeController@update',$home->id], 'class' => 'form-horizontal', 'files' => 'true']) !!} 
Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download