Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 6dbbb3c

Browse files
committed
[#2165] Filling in a few more changes of pattern -> path
1 parent d35b34f commit 6dbbb3c

File tree

7 files changed

+13
-13
lines changed

7 files changed

+13
-13
lines changed

book/security.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1709,7 +1709,7 @@ a route so that you can use it to generate the URL:
17091709
17101710
# app/config/routing.yml
17111711
logout:
1712-
pattern: /logout
1712+
path: /logout
17131713
17141714
.. code-block:: xml
17151715
@@ -1720,7 +1720,7 @@ a route so that you can use it to generate the URL:
17201720
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
17211721
xsi:schemaLocation="http://symfony.com/schema/routing http://symfony.com/schema/routing/routing-1.0.xsd">
17221722
1723-
<route id="logout" pattern="/logout" />
1723+
<route id="logout" path="/logout" />
17241724
17251725
</routes>
17261726

cookbook/configuration/apache_router.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ To test that it's working, let's create a very basic route for demo bundle:
3737
3838
# app/config/routing.yml
3939
hello:
40-
pattern: /hello/{name}
40+
path: /hello/{name}
4141
defaults: { _controller: AcmeDemoBundle:Demo:hello }
4242
4343

cookbook/controller/service.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ value:
2222
.. code-block:: yaml
2323
2424
my_controller:
25-
pattern: /
25+
path: /
2626
defaults: { _controller: my_controller:indexAction }
2727
2828
To use a controller in this way, it must be defined in the service container

cookbook/templating/PHP.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -282,7 +282,7 @@ pattern:
282282
283283
# src/Acme/HelloBundle/Resources/config/routing.yml
284284
hello: # The route name
285-
pattern: /hello/{name}
285+
path: /hello/{name}
286286
defaults: { _controller: AcmeHelloBundle:Hello:index }
287287
288288
Using Assets: images, JavaScripts, and stylesheets

cookbook/templating/render_without_controller.rst

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ can do this without creating a controller:
1919
.. code-block:: yaml
2020
2121
acme_privacy:
22-
pattern: /privacy
22+
path: /privacy
2323
defaults:
2424
_controller: FrameworkBundle:Template:template
2525
template: 'AcmeBundle:Static:privacy.html.twig'
@@ -32,7 +32,7 @@ can do this without creating a controller:
3232
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
3333
xsi:schemaLocation="http://symfony.com/schema/routing http://symfony.com/schema/routing/routing-1.0.xsd">
3434
35-
<route id="acme_privacy" pattern="/privacy">
35+
<route id="acme_privacy" path="/privacy">
3636
<default key="_controller">FrameworkBundle:Template:template</default>
3737
<default key="template">AcmeBundle:Static:privacy.html.twig</default>
3838
</route>
@@ -90,7 +90,7 @@ other variables in your route, you can control exactly how your page is cached:
9090
.. code-block:: yaml
9191
9292
acme_privacy:
93-
pattern: /privacy
93+
path: /privacy
9494
defaults:
9595
_controller: FrameworkBundle:Template:template
9696
template: 'AcmeBundle:Static:privacy.html.twig'
@@ -105,7 +105,7 @@ other variables in your route, you can control exactly how your page is cached:
105105
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
106106
xsi:schemaLocation="http://symfony.com/schema/routing http://symfony.com/schema/routing/routing-1.0.xsd">
107107
108-
<route id="acme_privacy" pattern="/privacy">
108+
<route id="acme_privacy" path="/privacy">
109109
<default key="_controller">FrameworkBundle:Template:template</default>
110110
<default key="template">AcmeBundle:Static:privacy.html.twig</default>
111111
<default key="maxAge">86400</default>

quick_tour/the_big_picture.rst

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -179,7 +179,7 @@ Routing
179179
~~~~~~~
180180

181181
Symfony2 routes the request to the code that handles it by trying to match the
182-
requested URL against some configured patterns. By default, these patterns
182+
requested URL against some configured paths. By default, these paths
183183
(called routes) are defined in the ``app/config/routing.yml`` configuration
184184
file. When you're in the ``dev`` :ref:`environment<quick-tour-big-picture-environments>` -
185185
indicated by the app_**dev**.php front controller - the ``app/config/routing_dev.yml``
@@ -190,7 +190,7 @@ these "demo" pages are placed in that file:
190190
191191
# app/config/routing_dev.yml
192192
_welcome:
193-
pattern: /
193+
path: /
194194
defaults: { _controller: AcmeDemoBundle:Welcome:index }
195195
196196
_demo:
@@ -331,7 +331,7 @@ file, routes are defined as annotations on action methods::
331331
// ...
332332
}
333333

334-
The ``@Route()`` annotation defines a new route with a pattern of
334+
The ``@Route()`` annotation defines a new route with a path of
335335
``/hello/{name}`` that executes the ``helloAction`` method when matched. A
336336
string enclosed in curly brackets like ``{name}`` is called a placeholder. As
337337
you can see, its value can be retrieved through the ``$name`` method argument.

quick_tour/the_controller.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ automatically selects the right template, here ``hello.xml.twig``:
4141
That's all there is to it. For standard formats, Symfony2 will also
4242
automatically choose the best ``Content-Type`` header for the response. If
4343
you want to support different formats for a single action, use the ``{_format}``
44-
placeholder in the route pattern instead::
44+
placeholder in the route path instead::
4545

4646
// src/Acme/DemoBundle/Controller/DemoController.php
4747
use Sensio\Bundle\FrameworkExtraBundle\Configuration\Route;

0 commit comments

Comments
 (0)