File tree Expand file tree Collapse file tree 1 file changed +3
-5
lines changed Expand file tree Collapse file tree 1 file changed +3
-5
lines changed Original file line number Diff line number Diff line change @@ -37,7 +37,6 @@ Register the bundle in `app/AppKernel.php`:
37
37
38
38
``` php
39
39
// app/AppKernel.php
40
-
41
40
public function registerBundles()
42
41
{
43
42
return array(
@@ -51,7 +50,6 @@ Register the routing definition in `app/config/routing.yml`:
51
50
52
51
``` yml
53
52
# app/config/routing.yml
54
-
55
53
fos_js_routing :
56
54
resource : " @FOSJsRoutingBundle/Resources/config/routing/routing.xml"
57
55
` ` `
66
64
67
65
Add these two lines in your layout:
68
66
69
- ` ` ` html
67
+ ` ` `
70
68
<script src="{{ asset('bundles/fosjsrouting/js/router.js') }}"></script>
71
69
<script src="{{ path('fos_js_routing_js', {"callback" : " fos.Router.setData" }) }}"></script>
72
70
` ` `
@@ -76,7 +74,7 @@ add the two JavaScript files above loaded at some point in your web page.
76
74
77
75
### Generating URIs
78
76
79
- Then, it 's as simple as calling:
77
+ It 's as simple as calling:
80
78
81
79
` ` ` javascript
82
80
Routing.generate('route_id', /* your params */)
@@ -113,7 +111,7 @@ Or using annotations:
113
111
*/
114
112
public function exposedAction($foo)
115
113
116
- You can do :
114
+ You can use the ` generate()` method that way :
117
115
118
116
` ` ` javascript
119
117
Routing.generate('my_route_to_expose', { id: 10 });
You can’t perform that action at this time.
0 commit comments