Append to Request

Submitted by wolf - 9 months ago

This snippet will allow you to add to the request. Tested in Laravel 5.2

 public function store(Request $request, Property $property)
    {        
        $request->request->add(['key' => 'value']);
        //dd($request->all());
        $property->create($request->all());
        return back();
    }
comments powered by Disqus

Ads cover the costs of maintaining Laravel-tricks