@@ -33,9 +33,10 @@ lives::
33
33
$kernel->loadClassCache();
34
34
$kernel->handle(Request::createFromGlobals())->send();
35
35
36
- The controller first requires the ``bootstrap.php.cache `` file, which bootstraps
37
- the framework and registers the autoloader (see below). Then, it uses a kernel
38
- class, ``AppKernel `` in this case, to bootstrap the application.
36
+ The controller first bootstraps the application using a kernel class (``AppKernel ``
37
+ in this case). Then, it creates the ``Request `` object using the PHP's global
38
+ variables and passes it to the kernel. The last step is to send back to the user
39
+ the response contents returned by the kernel.
39
40
40
41
.. _the-app-dir :
41
42
@@ -54,8 +55,7 @@ This class must implement two methods:
54
55
(more on this later).
55
56
56
57
Autoloading is handled automatically via `Composer `_, which means that you
57
- can use any PHP classes without doing anything at all! If you need more flexibility,
58
- you can extend the autoloader in the ``app/autoload.php `` file. All dependencies
58
+ can use any PHP classes without doing anything at all! All dependencies
59
59
are stored under the ``vendor/ `` directory, but this is just a convention.
60
60
You can store them wherever you want, globally on your server or locally
61
61
in your projects.
@@ -69,12 +69,13 @@ Symfony2, the :term:`bundle` system.
69
69
A bundle is kind of like a plugin in other software. So why is it called a
70
70
*bundle * and not a *plugin *? This is because *everything * is a bundle in
71
71
Symfony2, from the core framework features to the code you write for your
72
- application. Bundles are first-class citizens in Symfony2. This gives you
73
- the flexibility to use pre-built features packaged in third-party bundles
74
- or to distribute your own bundles. It makes it easy to pick and choose which
75
- features to enable in your application and optimize them the way you want.
76
- And at the end of the day, your application code is just as *important * as
77
- the core framework itself.
72
+ application.
73
+
74
+ Bundles are first-class citizens in Symfony2. This gives you the flexibility
75
+ to use pre-built features packaged in third-party bundles or to distribute your
76
+ own bundles. It makes it easy to pick and choose which features to enable in
77
+ your application and optimize them the way you want. And at the end of the day,
78
+ your application code is just as *important * as the core framework itself.
78
79
79
80
Registering a Bundle
80
81
~~~~~~~~~~~~~~~~~~~~
@@ -109,14 +110,14 @@ a single ``Bundle`` class that describes it::
109
110
110
111
In addition to the AcmeDemoBundle that was already talked about, notice
111
112
that the kernel also enables other bundles such as the FrameworkBundle,
112
- DoctrineBundle, SwiftmailerBundle, and AsseticBundle bundle.
113
- They are all part of the core framework.
113
+ DoctrineBundle, SwiftmailerBundle, and AsseticBundle bundle. They are all part
114
+ of the core framework.
114
115
115
116
Configuring a Bundle
116
117
~~~~~~~~~~~~~~~~~~~~
117
118
118
119
Each bundle can be customized via configuration files written in YAML, XML, or
119
- PHP. Have a look at the default configuration:
120
+ PHP. Have a look at the default Symfony configuration:
120
121
121
122
.. code-block :: yaml
122
123
@@ -181,9 +182,9 @@ PHP. Have a look at the default configuration:
181
182
password : " %mailer_password%"
182
183
spool : { type: memory }
183
184
184
- Each entry like ``framework `` defines the configuration for a specific bundle.
185
- For example, ``framework `` configures the FrameworkBundle while `` swiftmailer ``
186
- configures the SwiftmailerBundle.
185
+ Each first level entry like ``framework ``, `` twig `` or `` doctrine `` defines the
186
+ configuration for a specific bundle. For example, ``framework `` configures the
187
+ FrameworkBundle while `` swiftmailer `` configures the SwiftmailerBundle.
187
188
188
189
Each :term: `environment ` can override the default configuration by providing a
189
190
specific configuration file. For example, the ``dev `` environment loads the
0 commit comments