php - Laravel route returns 404 (Laravel 6.6.2)

Solution:

Thanks for the solution from lagbox.

The problem was that I was using $ in the defintion of the route parameter. Removing it solved the problem.

Answer

Solution:

While declaring parameters in the route.php, no need to declare with '$'. Just simply, write by {id} or {teamid}, rest I think is OK.

Here is a documentation on how to add parameters to the URL in routes.

Also, I think, you should upgrade to Laravel 8, there are some cool features in it.

Though, you already got your solutions, hope this too helps. Thank You :)

Source