Skip to content

Commit 674becd

Browse files
committed
use valid XML in code block
1 parent e3f229d commit 674becd

File tree

12 files changed

+30
-24
lines changed

12 files changed

+30
-24
lines changed

book/service_container.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -269,7 +269,7 @@ parameter and uses it in the service definition.
269269

270270
.. code-block:: xml
271271
272-
<argument type="string">http://symfony.com/?foo=%%s&bar=%%d</argument>
272+
<argument type="string">http://symfony.com/?foo=%%s&amp;bar=%%d</argument>
273273
274274
.. caution::
275275

components/dependency_injection/parameters.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -155,7 +155,7 @@ the parameter value in one place if needed.
155155
156156
.. code-block:: xml
157157
158-
<argument>http://symfony.com/?foo=%%s&bar=%%d</argument>
158+
<argument>http://symfony.com/?foo=%%s&amp;bar=%%d</argument>
159159
160160
.. code-block:: php
161161

components/intl.rst

+4-2
Original file line numberDiff line numberDiff line change
@@ -126,8 +126,10 @@ code::
126126

127127
.. code-block:: json
128128
129-
"require: {
130-
"symfony/icu": "1.1.*"
129+
{
130+
"require": {
131+
"symfony/icu": "1.1.*"
132+
}
131133
}
132134
133135
Set the version to

cookbook/assetic/apply_to_option.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -142,7 +142,7 @@ In this case you can specify that the ``coffee`` filter is applied to all
142142
bin: /usr/bin/coffee
143143
node: /usr/bin/node
144144
node_paths: [/usr/lib/node_modules/]
145-
apply_to: "\.coffee$"
145+
apply_to: '\.coffee$'
146146
147147
.. code-block:: xml
148148

cookbook/configuration/override_dir_structure.rst

-2
Original file line numberDiff line numberDiff line change
@@ -177,12 +177,10 @@ The change in the ``composer.json`` will look like this:
177177
.. code-block:: json
178178
179179
{
180-
...
181180
"config": {
182181
"bin-dir": "bin",
183182
"vendor-dir": "/some/dir/vendor"
184183
},
185-
...
186184
}
187185
188186
Then, update the path to the ``autoload.php`` file in ``app/autoload.php``::

cookbook/deployment/heroku.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -167,7 +167,7 @@ variables, you can issue a single command to prepare your app for a deployment:
167167
Next up, it's finally time to deploy your application to Heroku. If you are
168168
doing this for the very first time, you may see a message such as the following:
169169

170-
.. code-block:: bash
170+
.. code-block:: text
171171
172172
The authenticity of host 'heroku.com (50.19.85.132)' can't be established.
173173
RSA key fingerprint is 8b:48:5e:67:0e:c9:16:47:32:f2:87:0c:1f:c8:60:ad.

cookbook/doctrine/mongodb_session_storage.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -162,7 +162,7 @@ Because MongoDB uses dynamic collection schemas, you do not need to do anything
162162
session collection. However, you may want to add an index to improve garbage collection performance.
163163
From the `MongoDB shell`_:
164164

165-
.. code-block:: sql
165+
.. code-block:: text
166166
167167
use session_db
168168
db.session.ensureIndex( { "expires_at": 1 }, { expireAfterSeconds: 0 } )

cookbook/install/unstable_versions.rst

-1
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,6 @@ dependency as follows:
4141
4242
{
4343
"require": {
44-
// ...
4544
"symfony/symfony" : "2.7.*@dev"
4645
}
4746
}

cookbook/logging/monolog.rst

+10-5
Original file line numberDiff line numberDiff line change
@@ -252,17 +252,22 @@ option of your handler to ``rotating_file``:
252252
.. code-block:: xml
253253
254254
<!-- app/config/config_dev.xml -->
255-
<?xml version="1.0" charset="UTF-8" ?>
256-
<container xmlns=''http://symfony.com/schema/dic/services"
257-
xmlns:monolog="http://symfony.com/schema/dic/monolog">
255+
<?xml version="1.0" encoding="UTF-8" ?>
256+
<container xmlns="http://symfony.com/schema/dic/services"
257+
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
258+
xmlns:monolog="http://symfony.com/schema/dic/monolog"
259+
xsi:schemaLocation="http://symfony.com/schema/dic/services
260+
http://symfony.com/schema/dic/services/services-1.0.xsd
261+
http://symfony.com/schema/dic/monolog
262+
http://symfony.com/schema/dic/monolog/monolog-1.0.xsd">
258263
259264
<monolog:config>
265+
<!-- "max_files": max number of log files to keep
266+
defaults to zero, which means infinite files -->
260267
<monolog:handler name="main"
261268
type="rotating_file"
262269
path="%kernel.logs_dir%/%kernel.environment%.log"
263270
level="debug"
264-
<!-- max number of log files to keep
265-
defaults to zero, which means infinite files -->
266271
max_files="10"
267272
/>
268273
</monolog:config>

cookbook/logging/monolog_email.rst

+7-6
Original file line numberDiff line numberDiff line change
@@ -41,24 +41,25 @@ it is broken down.
4141
.. code-block:: xml
4242
4343
<!-- app/config/config_prod.xml -->
44+
<?xml version="1.0" encoding="UTF-8" ?>
4445
<container xmlns="http://symfony.com/schema/dic/services"
4546
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
4647
xmlns:monolog="http://symfony.com/schema/dic/monolog"
4748
xsi:schemaLocation="http://symfony.com/schema/dic/services http://symfony.com/schema/dic/services/services-1.0.xsd
4849
http://symfony.com/schema/dic/monolog http://symfony.com/schema/dic/monolog/monolog-1.0.xsd">
4950
5051
<monolog:config>
52+
<!--
53+
To also log 400 level errors (but not 404's):
54+
action-level="error"
55+
And add this child inside this monolog:handler
56+
<monolog:excluded-404>^/</monolog:excluded-404>
57+
-->
5158
<monolog:handler
5259
name="mail"
5360
type="fingers_crossed"
5461
action-level="critical"
5562
handler="buffered"
56-
<!--
57-
To also log 400 level errors (but not 404's):
58-
action-level="error"
59-
And add this child inside this monolog:handler
60-
<monolog:excluded-404>^/</monolog:excluded-404>
61-
-->
6263
/>
6364
<monolog:handler
6465
name="buffered"

cookbook/symfony1.rst

+4-2
Original file line numberDiff line numberDiff line change
@@ -170,8 +170,10 @@ from specific directories without defining a dependency:
170170

171171
.. code-block:: json
172172
173-
"autoload": {
174-
"psr-0": { "": "src/" }
173+
{
174+
"autoload": {
175+
"psr-0": { "": "src/" }
176+
}
175177
}
176178
177179
This means that if a class is not found in the ``vendor`` directory, Composer

cookbook/testing/bootstrap.rst

-1
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,6 @@ with ``tests.bootstrap.php``:
2828
2929
<!-- ... -->
3030
<phpunit
31-
...
3231
bootstrap = "tests.bootstrap.php"
3332
>
3433

0 commit comments

Comments
 (0)