I have check box like this:
<input {{isset($shop['private_post'])&&$shop['private_post']=='Yes' ? 'checked' : ''}} id="private_post" value="Yes" type="checkbox" name="private_post">
in controller :
$shop= shop::find($request['id']);
$shop->update($request->all());
In edit mode When I checkbox true work correctly but when I unchecked checkbox dose not work.
I create dynamically checkbox and I can not use this command
If(!isset($request['private_post']))
$request['private_post']=0;
$shop= shop::find($request['id']);
$shop->update($request->all());