File tree Expand file tree Collapse file tree 2 files changed +9
-4
lines changed
Filter options
Expand file tree Collapse file tree 2 files changed +9
-4
lines changed
Original file line number Diff line number Diff line change @@ -32,6 +32,11 @@ as the "parent" of your bundle::
32
32
By making this simple change, you can now override several parts of the ``FOSUserBundle ``
33
33
simply by creating a file with the same name.
34
34
35
+ .. note ::
36
+
37
+ Despite the method name, there is no parent/child relationship between
38
+ the bundles, it is just a way to extend and override an existing bundle.
39
+
35
40
Overriding Controllers
36
41
~~~~~~~~~~~~~~~~~~~~~~
37
42
Original file line number Diff line number Diff line change @@ -295,11 +295,11 @@ Extending Bundles
295
295
296
296
If you follow these conventions, then you can use :doc: `bundle inheritance</cookbook/bundles/inheritance> `
297
297
to "override" files, controllers or templates. For example, you can create
298
- a bundle - ``AcmeNewBundle `` - and specify that its parent is ``AcmeDemoBundle ``.
298
+ a bundle - ``AcmeNewBundle `` - and specify that it overrides ``AcmeDemoBundle ``.
299
299
When Symfony loads the ``AcmeDemoBundle:Welcome:index `` controller, it will
300
- first look for the ``WelcomeController `` class in ``AcmeNewBundle `` and then
301
- look inside ``AcmeDemoBundle ``. This means that one bundle can override almost
302
- any part of another bundle!
300
+ first look for the ``WelcomeController `` class in ``AcmeNewBundle `` and, if
301
+ not exists, then look inside ``AcmeDemoBundle ``. This means that one bundle
302
+ can override almost any part of another bundle!
303
303
304
304
Do you understand now why Symfony2 is so flexible? Share your bundles between
305
305
applications, store them locally or globally, your choice.
You can’t perform that action at this time.
0 commit comments