Hi,
Laravel 5.2 here.
I can't save my checkbox values to db
$data = $request->all();
$data["uid"] = Auth::user()->id;
$new_ad = \App\Ad::Create($data);
Everything is saved other than the checkbox values. All the required values have been added to the $fillable variable. When I dd( $request->all()) I can see the checkboxes having been checked and their value is 'on'. So the controller is getting the getting the values that have to be written into the database, but it's just not happening. Any ideas why?
Sign in to participate in this thread!
The Laravel portal for problem solving, knowledge sharing and community building.
The community