Skip to content

Commit 28d11a9

Browse files
committed
Fixed code examples in cookbook/configuration
1 parent 7b4fd66 commit 28d11a9

File tree

3 files changed

+8
-16
lines changed

3 files changed

+8
-16
lines changed

cookbook/configuration/environments.rst

Lines changed: 6 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,7 @@ class:
3636
.. code-block:: php
3737
3838
// app/AppKernel.php
39+
3940
// ...
4041
4142
class AppKernel extends Kernel
@@ -63,21 +64,18 @@ easily and transparently:
6364
6465
imports:
6566
- { resource: config.yml }
66-
6767
# ...
6868
6969
.. code-block:: xml
7070
7171
<imports>
7272
<import resource="config.xml" />
7373
</imports>
74-
7574
<!-- ... -->
7675
7776
.. code-block:: php
7877
7978
$loader->import('config.php');
80-
8179
// ...
8280
8381
To share common configuration, each environment's configuration file
@@ -108,8 +106,7 @@ activated by modifying the default value in the ``dev`` configuration file:
108106
109107
<webprofiler:config
110108
toolbar="true"
111-
# ...
112-
/>
109+
... />
113110
114111
.. code-block:: php
115112
@@ -118,7 +115,7 @@ activated by modifying the default value in the ``dev`` configuration file:
118115
119116
$container->loadFromExtension('web_profiler', array(
120117
'toolbar' => true,
121-
// ..
118+
...,
122119
));
123120
124121
.. index::
@@ -208,9 +205,9 @@ environment by using this code and changing the environment string.
208205
$container->loadFromExtension('doctrine', array(
209206
'dbal' => array(
210207
'logging' => '%kernel.debug%',
211-
// ...
208+
...,
212209
),
213-
// ...
210+
...
214211
));
215212
216213
.. index::
@@ -237,7 +234,6 @@ The best way to accomplish this is via a new environment called, for example,
237234
.. code-block:: yaml
238235
239236
# app/config/config_benchmark.yml
240-
241237
imports:
242238
- { resource: config_prod.yml }
243239
@@ -247,7 +243,6 @@ The best way to accomplish this is via a new environment called, for example,
247243
.. code-block:: xml
248244
249245
<!-- app/config/config_benchmark.xml -->
250-
251246
<imports>
252247
<import resource="config_prod.xml" />
253248
</imports>
@@ -259,7 +254,6 @@ The best way to accomplish this is via a new environment called, for example,
259254
.. code-block:: php
260255
261256
// app/config/config_benchmark.php
262-
263257
$loader->import('config_prod.php')
264258
265259
$container->loadFromExtension('framework', array(
@@ -348,4 +342,4 @@ includes the following:
348342
Going Further
349343
-------------
350344

351-
Read the article on :doc:`/cookbook/configuration/external_parameters`.
345+
Read the article on :doc:`/cookbook/configuration/external_parameters`.

cookbook/configuration/external_parameters.rst

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -104,8 +104,7 @@ key, and define the type as ``constant``.
104104
<?xml version="1.0" encoding="UTF-8"?>
105105
106106
<container xmlns="http://symfony.com/schema/dic/services"
107-
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
108-
>
107+
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
109108
110109
<parameters>
111110
<parameter key="global.constant.value" type="constant">GLOBAL_CONSTANT</parameter>
@@ -164,7 +163,6 @@ the symfony service container.
164163
.. code-block:: php
165164
166165
// app/config/parameters.php
167-
168166
include_once('/path/to/drupal/sites/default/settings.php');
169167
$container->setParameter('drupal.database.url', $db_url);
170168

cookbook/configuration/pdo_session_storage.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ configuration format of your choice):
8282
$container->loadFromExtension('framework', array(
8383
// ...
8484
'session' => array(
85-
// ...
85+
...,
8686
'storage_id' => 'session.storage.pdo',
8787
),
8888
));

0 commit comments

Comments
 (0)