Answers for "laravel change post request before save"

PHP
1

laravel change post request before save

public function store(Request $request)
{
    $data = $request->all();
    $data['hostname'] = gethostbyaddr($_SERVER['REMOTE_ADDR'];

    Systems::create($data);
}
Posted by: Guest on May-03-2020

Browse Popular Code Answers by Language