@@ -9,8 +9,8 @@ Installing Symfony2
9
9
-------------------
10
10
11
11
First, check that the PHP version installed on your computer meets the Symfony2
12
- requirements: 5.3.3 or higher. Then, open a command console and execute the
13
- following command to install the latest version of Symfony2 in the ``myproject/ ``
12
+ requirements: 5.3.3 or higher. Then, open a console and execute the following
13
+ command to install the latest version of Symfony2 in the ``myproject/ ``
14
14
directory:
15
15
16
16
.. code-block :: bash
@@ -145,7 +145,7 @@ will be executed. In the next section, you'll learn exactly what that means.
145
145
146
146
.. tip ::
147
147
148
- In addition to YAML format , routes can be configured in XML or PHP files
148
+ In addition to YAML files , routes can be configured in XML or PHP files
149
149
and even embedded in PHP annotations. This flexibility is one of the main
150
150
features of Symfony2, a framework that never imposes you a particular
151
151
configuration format.
@@ -162,7 +162,7 @@ controller might create the response by hand, based on the request::
162
162
163
163
use Symfony\Component\HttpFoundation\Response;
164
164
165
- $name = $request->query-> get('name');
165
+ $name = $request->get('name');
166
166
167
167
return new Response('Hello '.$name);
168
168
@@ -322,11 +322,13 @@ environment.
322
322
323
323
.. _quick-tour-big-picture-environments-intro :
324
324
325
- So what *is * an environment? An :term: `Environment ` is a simple string (e.g.
326
- ``dev `` or ``prod ``) that represents a group of configuration that's used
327
- to run your application.
325
+ So what *is * an environment? An :term: `Environment ` represents a group of
326
+ configuration that's used to run your application. Symfony2 defines by default
327
+ two environments: ``dev `` (suited for when developing the application locally)
328
+ and ``prod `` (optimized for when executing the application on production).
328
329
329
- Typically, you put your common configuration in ``config.yml `` and override
330
+ Typically, the environments share a large amount of configuration options. For
331
+ that reason, you put your common configuration in ``config.yml `` and override
330
332
where necessary in the specific configuration file for each environment:
331
333
332
334
.. code-block :: yaml
@@ -340,8 +342,8 @@ where necessary in the specific configuration file for each environment:
340
342
intercept_redirects : false
341
343
342
344
In this example, the ``dev `` environment loads the ``config_dev.yml `` configuration
343
- file, which itself imports the global ``config.yml `` file and then modifies it by
344
- enabling the web debug toolbar.
345
+ file, which itself imports the common ``config.yml `` file and then modifies it
346
+ by enabling the web debug toolbar.
345
347
346
348
When you visit the ``app_dev.php `` file in your browser, you're executing
347
349
your Symfony application in the ``dev `` environment. To visit your application
0 commit comments