Skip to content

Commit 5c56059

Browse files
committed
[#2128] Fixes per @wouterj's suggestions
1 parent 7ac1162 commit 5c56059

File tree

1 file changed

+17
-5
lines changed

1 file changed

+17
-5
lines changed

reference/configuration/framework.rst

Lines changed: 17 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -99,10 +99,24 @@ trusted_proxies
9999
Configures the IP addresses that should be trusted as proxies. For more details,
100100
see :doc:`/components/http_foundation/trusting_proxies`.
101101

102-
.. code-block:: yaml
102+
.. configuration-block::
103103

104-
framework:
105-
trusted_proxies: [192.0.0.1]
104+
.. code-block:: yaml
105+
106+
framework:
107+
trusted_proxies: [192.0.0.1]
108+
109+
.. code-block:: xml
110+
111+
<framework:config trusted-proxies="192.0.0.1">
112+
<!-- ... -->
113+
</framework>
114+
115+
.. code-block:: php
116+
117+
$container->loadFromExtension('framework', array(
118+
'trusted_proxies' => array('192.0.0.1'),
119+
));
106120
107121
trust_proxy_headers
108122
~~~~~~~~~~~~~~~~~~~
@@ -113,8 +127,6 @@ trust_proxy_headers
113127
Symfony 2.3. See `trusted_proxies`_ and :doc:`/components/http_foundation/trusting_proxies`
114128
for details on how to properly trust proxy data.
115129

116-
**Deprecated**: This option will be removed in Symfony 2.3. Instead, use
117-
118130
**type**: ``Boolean``
119131

120132
Configures if HTTP headers (like ``HTTP_X_FORWARDED_FOR``, ``X_FORWARDED_PROTO``, and

0 commit comments

Comments
 (0)