Hi friends, When I Implement the follow code I get an Error on Helpers Line 454
{!! Form::text('name_departament', ['class'=>'form-control']) !!}
Error ErrorException in helpers.php line 454: htmlentities() expects parameter 1 to be string, array given (View: /var/www/html/pruebalaravel5/resources/views/departaments/create.blade.php)
Thanks.
{!! Form::text(name, value, options) !!}
{!! Form::text('name_departament',' ', ['class'=>'form-control']) !!}
As you can see in ABDELRHMAN's comment, the second parameter for Form::text()
should be the actual value of the input you're creating. In your case, this can be either and empty string (''
), or you can write it up like this:
{!! Form::text('name_departament', null, ['class'=>'form-control']) !!}
Hope that helped :-)
Sign in to participate in this thread!
The Laravel portal for problem solving, knowledge sharing and community building.
The community