Routing

Routing associates a URL and an HTTP method with code, defined in routes/web.php for the web. A route can receive parameters, a name to generate URLs with route(), and middleware. It returns a view, a response or calls a controller.

Example

Route::get('/produits/{id}', [ProduitController::class, 'show'])->name('produits.show');

Related concepts

The whole glossary