K
K
Konstantin Teploukhov2019-02-18 21:14:39
Laravel
Konstantin Teploukhov, 2019-02-18 21:14:39

Something strange with the removal from the database?

In general, at the rate I'm making a small site on Laravel. The author of the course has all the rules, but I don’t. The difference in versions is small (he has 5.4 and I have 5.7)

Here is the error
5c6af5f9b8b1d339088774.jpeg

Answer the question

In order to leave comments, you need to log in

2 answer(s)
K
Kirill Arutyunov, 2019-02-18
@arutyunov

Check routes and allowed request types. The error tells you that you are sending an invalid request to the route. For example, an action can only accept POST requests, and you send DELETE to it.

A
Alex Wells, 2019-02-19
@Alex_Wells

So where are you sending the request? I see that this is a DELETE request, which means it should go, judging by your routes, to /posts/123, where instead of 123 is the ID of your post. If it was originally supposed to do something else, and not DELETE, then change it ..
The error is easily googled, I don’t even know why I paint it.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question