File tree Expand file tree Collapse file tree 2 files changed +7
-4
lines changed Expand file tree Collapse file tree 2 files changed +7
-4
lines changed Original file line number Diff line number Diff line change @@ -691,15 +691,15 @@ will automatically fetch them::
691691 * Fetch via primary key because {id} is in the route.
692692 */
693693 #[Route('/product/{id}')]
694- public function showByPk(Post $post ): Response
694+ public function showByPk(Product $product ): Response
695695 {
696696 }
697697
698698 /**
699699 * Perform a findOneBy() where the slug property matches {slug}.
700700 */
701701 #[Route('/product/{slug}')]
702- public function showBySlug(Post $post ): Response
702+ public function showBySlug(Product $product ): Response
703703 {
704704 }
705705
Original file line number Diff line number Diff line change @@ -2234,8 +2234,11 @@ It will help you understand and hopefully fixing unexpected behavior in your app
22342234Generating URLs
22352235---------------
22362236
2237- Routing systems are bidirectional: 1) they associate URLs with controllers (as
2238- explained in the previous sections); 2) they generate URLs for a given route.
2237+ Routing systems are bidirectional:
2238+
2239+ 1. they associate URLs with controllers (as explained in the previous sections);
2240+ 2. they generate URLs for a given route.
2241+
22392242Generating URLs from routes allows you to not write the ``<a href="..."> ``
22402243values manually in your HTML templates. Also, if the URL of some route changes,
22412244you only have to update the route configuration and all links will be updated.
You can’t perform that action at this time.
0 commit comments