skip to Main Content

Php versions – Use of undefined constant login – assumed 'login' (this will throw an Error in a future version of PHP) when trying to logout

when ever i want to logout, it always show "Use of undefined constant login - assumed 'login'" error. what did i do wrong? web.php route::get('/logout','AuthController@logout')->name('logout'); route::get('/','PagesController@home')->name('home'); AuthController.php public function getLogin(){ return view('login'); } public function postLogin(Request $request){ if(!Auth::attempt(['email' => $request->email,…

VIEW QUESTION

Get daily data for Laravel 5.4 – Phpmyadmin

I want to get daily data from my database. I try 2 code and both are not working for me. $sales=Sale::whereDate('created_at', '=', Carbon::today()); The error that I got: Class 'AppHttpControllersCarbon' not found and when I try $sales=Sale::whereDay('created_at', now()->day)->get(); The error…

VIEW QUESTION
Back To Top
Search