Answer the question
In order to leave comments, you need to log in
What is the correct way to write "API" for contact forms?
Laravel 5.4
In general, I am writing my bicycle rocket purely for myself, for learning Laravel. It is very sad that Google gives out information for version 5.3 at best.
The essence of the task: there are various forms on the site (let there be 2 of them), I want to send them to the server with Ajax (as I understand it, this requires a route in api.php, not web.php) and check (as I understand it for this middleware is needed) respond with an error or confirmation. When passing the "verification", the data will be - go to the PM by mail / post, write to the database and somewhere else (there are no problems with all this).
Substantive questions:
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question