D
D
DocTypeMaster2021-02-09 16:51:14
Laravel
DocTypeMaster, 2021-02-09 16:51:14

How to return function processing response in Laravel?

Friends, I'm just getting into Laravel, and so far I came across such a problem

. I have a form on the "Card" page that creates cards, the form has an action on a certain "card / check" handler

Route::post('/card/check', 'App\Http\Controllers\[email protected]')->middleware(['auth'])->name('card');

When the function is working, I want to send a notification to the "Card" page that everything is fine or an error, but this return returns me to the "card / check" Tell me how to properly process forms in Laravel in order to return notifications or any other information, relatively speaking, to the same place we started data processing Thank you in advance!
return view('createcard', ['succses' =>$succses]);

Answer the question

In order to leave comments, you need to log in

1 answer(s)
S
Sergey delphinpro, 2021-02-09
@delphinpro

redirects https://laravel.com/docs/8.x/responses#redirects
redirect with data https://laravel.com/docs/8.x/responses#redirecting...
separately about flash data https:// laravel.com/docs/8.x/session#flash-data

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question