app/Http/Controllers/CarController.php
/**
     * Store a newly created resource in storage.
     *
     * @param  \Illuminate\Http\Request  $request
     * @return \Illuminate\Http\Response
     */
Store a newly created resource in storage.
Store a newly created resource in storage .
public function store(Request $request)
    {
        $car = new Car();
        $car->make = $request->make;
        $car->model = $request->model;
        $car->save();
        return $car;
    }
public function store ( Request $ request ) { $ car = new Car ( ) ; $ car -> make = $ request -> make ; $ car -> model = $ request -> model ; $ car -> save ( ) ; return $ car ; }
Store a newly created resource in storage.
Store a newly created resource in storage .