Skip to content

Commit 84d43ac

Browse files
committed
typos, CS and PSR links fixed
1 parent 0bcc16b commit 84d43ac

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

62 files changed

+93
-97
lines changed

Diff for: README.markdown

+3-3
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,9 @@ Contributing
88

99
>**Note**
1010
>Unless you're documenting a feature that's new to a specific version of Symfony
11-
>(e.g. Symfony 2.3), all pull requests must be based off of the **2.2** branch,
11+
>(e.g. Symfony 2.3), all pull requests must be based off of the **2.2** branch,
1212
>**not** the master or 2.3 branch.
1313
1414
We love contributors! For more information on how you can contribute to the
15-
Symfony documentation, please read
16-
[Contributing to the Documentation](http://symfony.com/doc/current/contributing/documentation/overview.html)
15+
Symfony documentation, please read
16+
[Contributing to the Documentation](http://symfony.com/doc/current/contributing/documentation/overview.html)

Diff for: book/forms.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -1166,7 +1166,7 @@ form with many ``Product`` sub-forms). This is done by using the ``collection``
11661166
field type.
11671167
11681168
For more information see the ":doc:`/cookbook/form/form_collections`" cookbook
1169-
entry and the :doc:`collection </reference/forms/types/collection>` field type reference.
1169+
entry and the :doc:`collection </reference/forms/types/collection>` field type reference.
11701170
11711171
.. index::
11721172
single: Forms; Theming

Diff for: book/installation.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -140,7 +140,7 @@ Updating Vendors
140140

141141
At this point, you've downloaded a fully-functional Symfony project in which
142142
you'll start to develop your own application. A Symfony project depends on
143-
a number of external libraries. These are downloaded into the `vendor/` directory
143+
a number of external libraries. These are downloaded into the ``vendor/`` directory
144144
of your project via a library called `Composer`_.
145145

146146
Depending on how you downloaded Symfony, you may or may not need to update

Diff for: book/page_creation.rst

+4-4
Original file line numberDiff line numberDiff line change
@@ -42,10 +42,10 @@ also load specific bundles based on the selected environment. For example,
4242
Symfony2 comes with the WebProfilerBundle (described below), enabled only
4343
in the ``dev`` and ``test`` environments.
4444

45-
Symfony2 comes with two web-accessible front controllers: ``app_dev.php``
45+
Symfony2 comes with two web-accessible front controllers: ``app_dev.php``
4646
provides the ``dev`` environment, and ``app.php`` provides the ``prod`` environment.
4747
All web accesses to Symfony2 normally go through one of these front controllers.
48-
(The ``test`` environment is normally only used when running unit tests, and so
48+
(The ``test`` environment is normally only used when running unit tests, and so
4949
doesn't have a dedicated front controller. The console tool also provides a
5050
front controller that can be used with any environment.)
5151

@@ -555,7 +555,7 @@ You'll learn more about each of these directories in later chapters.
555555

556556
When Symfony is loading, a special file - ``vendor/autoload.php`` - is
557557
included. This file is created by Composer and will autoload all
558-
application files living in the `src/` folder as well as all
558+
application files living in the ``src/`` folder as well as all
559559
third-party libraries mentioned in the ``composer.json`` file.
560560

561561
Because of the autoloader, you never need to worry about using ``include``
@@ -868,7 +868,7 @@ Default Configuration Dump
868868
The ``config:dump-reference`` command was added in Symfony 2.1
869869

870870
You can dump the default configuration for a bundle in YAML to the console using
871-
the ``config:dump-reference`` command. Here is an example of dumping the default
871+
the ``config:dump-reference`` command. Here is an example of dumping the default
872872
FrameworkBundle configuration:
873873

874874
.. code-block:: text

Diff for: book/propel.rst

+4-4
Original file line numberDiff line numberDiff line change
@@ -134,7 +134,7 @@ Creating the Database Tables/Schema
134134
Now you have a usable ``Product`` class and all you need to persist it. Of
135135
course, you don't yet have the corresponding ``product`` table in your
136136
database. Fortunately, Propel can automatically create all the database tables
137-
needed for every known model in your application. To do this, run:
137+
needed for every known model in your application. To do this, run:
138138

139139
.. code-block:: bash
140140
@@ -153,7 +153,7 @@ Persisting Objects to the Database
153153
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
154154

155155
Now that you have a ``Product`` object and corresponding ``product`` table,
156-
you're ready to persist data to the database. From inside a controller, this
156+
you're ready to persist data to the database. From inside a controller, this
157157
is pretty easy. Add the following method to the ``DefaultController`` of the
158158
bundle::
159159

@@ -406,7 +406,7 @@ Fetching Related Objects
406406
~~~~~~~~~~~~~~~~~~~~~~~~
407407

408408
When you need to fetch associated objects, your workflow looks just like it did
409-
before. First, fetch a ``$product`` object and then access its related
409+
before. First, fetch a ``$product`` object and then access its related
410410
``Category``::
411411

412412
// ...
@@ -435,7 +435,7 @@ Lifecycle Callbacks
435435
-------------------
436436

437437
Sometimes, you need to perform an action right before or after an object is
438-
inserted, updated, or deleted. These types of actions are known as "lifecycle"
438+
inserted, updated, or deleted. These types of actions are known as "lifecycle"
439439
callbacks or "hooks", as they're callback methods that you need to execute
440440
during different stages of the lifecycle of an object (e.g. the object is
441441
inserted, updated, deleted, etc).

Diff for: book/templating.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -1091,7 +1091,7 @@ Global Template Variables
10911091
-------------------------
10921092

10931093
During each request, Symfony2 will set a global template variable ``app``
1094-
in both Twig and PHP template engines by default. The ``app`` variable
1094+
in both Twig and PHP template engines by default. The ``app`` variable
10951095
is a :class:`Symfony\\Bundle\\FrameworkBundle\\Templating\\GlobalVariables`
10961096
instance which will give you access to some application specific variables
10971097
automatically:

Diff for: book/testing.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -464,7 +464,7 @@ Redirecting
464464

465465
When a request returns a redirect response, the client does not follow
466466
it automatically. You can examine the response and force a redirection
467-
afterwards with the ``followRedirect()`` method::
467+
afterwards with the ``followRedirect()`` method::
468468

469469
$crawler = $client->followRedirect();
470470

Diff for: book/validation.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -168,7 +168,7 @@ You could also pass the collection of errors into a template.
168168
return $this->render('AcmeBlogBundle:Author:validate.html.twig', array(
169169
'errors' => $errors,
170170
));
171-
}
171+
}
172172
173173
Inside the template, you can output the list of errors exactly as needed:
174174

Diff for: components/class_loader/cache_class_loader.rst

+2-2
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,8 @@ for a class.
2020

2121
.. note::
2222

23-
Both the ``ApcClassLoader`` and the ``XcacheClassLoader`` can be used
24-
to cache Composer's `autoloader`_.
23+
Both the ``ApcClassLoader`` and the ``XcacheClassLoader`` can be used
24+
to cache Composer's `autoloader`_.
2525

2626
ApcClassLoader
2727
--------------

Diff for: components/class_loader/class_loader.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -81,4 +81,4 @@ or one of its children, the autoloader will first look for the class under the
8181
of the prefix registrations is significant in this case.
8282

8383
.. _PEAR: http://pear.php.net/manual/en/standards.naming.php
84-
.. _PSR-0: http://symfony.com/PSR0
84+
.. _PSR-0: http://www.php-fig.org/psr/psr-0/

Diff for: components/class_loader/map_class_loader.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -36,4 +36,4 @@ an instance of the ``MapClassLoader`` class::
3636
3737
$loader->register();
3838

39-
.. _PSR-0: http://symfony.com/PSR0
39+
.. _PSR-0: http://www.php-fig.org/psr/psr-0/

Diff for: components/dependency_injection/parameters.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -250,7 +250,7 @@ Constants as Parameters
250250
-----------------------
251251

252252
The container also has support for setting PHP constants as parameters. To
253-
take advantage of this feature, map the name of your constant to a parameter
253+
take advantage of this feature, map the name of your constant to a parameter
254254
key, and define the type as ``constant``.
255255

256256
.. configuration-block::

Diff for: components/event_dispatcher/introduction.rst

+2-2
Original file line numberDiff line numberDiff line change
@@ -445,7 +445,7 @@ EventDispatcher aware Events and Listeners
445445
The ``Event`` object contains a reference to the invoking dispatcher since Symfony 2.1
446446

447447
The ``EventDispatcher`` always injects a reference to itself in the passed event
448-
object. This means that all listeners have direct access to the
448+
object. This means that all listeners have direct access to the
449449
``EventDispatcher`` object that notified the listener via the passed ``Event``
450450
object's :method:`Symfony\\Component\\EventDispatcher\\Event::getDispatcher`
451451
method.
@@ -492,7 +492,7 @@ Dispatching another event from within a listener::
492492

493493
While this above is sufficient for most uses, if your application uses multiple
494494
``EventDispatcher`` instances, you might need to specifically inject a known
495-
instance of the ``EventDispatcher`` into your listeners. This could be done
495+
instance of the ``EventDispatcher`` into your listeners. This could be done
496496
using constructor or setter injection as follows:
497497

498498
Constructor injection::

Diff for: components/filesystem.rst

+2-2
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ Exists
6565
~~~~~~
6666

6767
:method:`Symfony\\Component\\Filesystem\\Filesystem::exists` checks for the
68-
presence of all files or directories and returns false if a file is missing::
68+
presence of all files or directories and returns ``false`` if a file is missing::
6969

7070
// this directory exists, return true
7171
$fs->exists('/tmp/photos');
@@ -222,7 +222,7 @@ isAbsolutePath
222222
~~~~~~~~~~~~~~
223223

224224
:method:`Symfony\\Component\\Filesystem\\Filesystem::isAbsolutePath` returns
225-
``true`` if the given path is absolute, false otherwise::
225+
``true`` if the given path is absolute, ``false`` otherwise::
226226

227227
// return true
228228
$fs->isAbsolutePath('/tmp');

Diff for: components/finder.rst

+2-2
Original file line numberDiff line numberDiff line change
@@ -258,8 +258,8 @@ Restrict files by last modified dates with the
258258

259259
$finder->date('since yesterday');
260260

261-
The comparison operator can be any of the following: ``>``, ``>=``, ``<``, '<=',
262-
'=='. You can also use ``since`` or ``after`` as an alias for ``>``, and
261+
The comparison operator can be any of the following: ``>``, ``>=``, ``<``, ``<=``,
262+
``==``. You can also use ``since`` or ``after`` as an alias for ``>``, and
263263
``until`` or ``before`` as an alias for ``<``.
264264

265265
The target value can be any date supported by the `strtotime`_ function.

Diff for: components/http_foundation/session_configuration.rst

+2-2
Original file line numberDiff line numberDiff line change
@@ -12,11 +12,11 @@ store and retrieve session data, and configuring session behaviour.
1212
Save Handlers
1313
~~~~~~~~~~~~~
1414

15-
The PHP session workflow has 6 possible operations that may occur. The normal
15+
The PHP session workflow has 6 possible operations that may occur. The normal
1616
session follows `open`, `read`, `write` and `close`, with the possibility of
1717
`destroy` and `gc` (garbage collection which will expire any old sessions: `gc`
1818
is called randomly according to PHP's configuration and if called, it is invoked
19-
after the `open` operation). You can read more about this at
19+
after the `open` operation). You can read more about this at
2020
`php.net/session.customhandler`_
2121

2222
Native PHP Save Handlers

Diff for: components/http_foundation/sessions.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -258,7 +258,7 @@ has a simple API
258258
Adds a flash message to the stack of specified type;
259259

260260
* :method:`Symfony\\Component\\HttpFoundation\\Session\\Flash\\FlashBagInterface::set`:
261-
Sets flashes by type; This method conveniently takes both singles messages as
261+
Sets flashes by type; This method conveniently takes both singles messages as
262262
a ``string`` or multiple messages in an ``array``.
263263

264264
* :method:`Symfony\\Component\\HttpFoundation\\Session\\Flash\\FlashBagInterface::get`:

Diff for: components/http_kernel/introduction.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -193,7 +193,7 @@ The only requirement is that it is a PHP callable - i.e. a function, method
193193
on an object, or a ``Closure``.
194194

195195
But *how* you determine the exact controller for a request is entirely up
196-
to your application. This is the job of the "controller resolver" - a class
196+
to your application. This is the job of the "controller resolver" - a class
197197
that implements :class:`Symfony\\Component\\HttpKernel\\Controller\\ControllerResolverInterface`
198198
and is one of the constructor arguments to ``HttpKernel``.
199199

Diff for: components/routing/hostname_pattern.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -125,7 +125,7 @@ instance, if you want to match both ``m.example.com`` and
125125
mobile_homepage:
126126
path: /
127127
host: "{subdomain}.example.com"
128-
defaults:
128+
defaults:
129129
_controller: AcmeDemoBundle:Main:mobileHomepage
130130
subdomain: m
131131
requirements:

Diff for: components/routing/introduction.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ placeholders as regular expressions.
8585
4. An array of options. These contain internal settings for the route and
8686
are the least commonly needed.
8787

88-
5. A host. This is matched against the host of the request. See
88+
5. A host. This is matched against the host of the request. See
8989
:doc:`/components/routing/hostname_pattern` for more details.
9090

9191
6. An array of schemes. These enforce a certain HTTP scheme (``http``, ``https``).

Diff for: contributing/code/standards.rst

+3-3
Original file line numberDiff line numberDiff line change
@@ -158,6 +158,6 @@ License
158158
* Symfony is released under the MIT license, and the license block has to be
159159
present at the top of every PHP file, before the namespace.
160160

161-
.. _`PSR-0`: https://github.com/php-fig/fig-standards/blob/master/accepted/PSR-0.md
162-
.. _`PSR-1`: https://github.com/php-fig/fig-standards/blob/master/accepted/PSR-1-basic-coding-standard.md
163-
.. _`PSR-2`: https://github.com/php-fig/fig-standards/blob/master/accepted/PSR-2-coding-style-guide.md
161+
.. _`PSR-0`: http://www.php-fig.org/psr/psr-0/
162+
.. _`PSR-1`: http://www.php-fig.org/psr/psr-1/
163+
.. _`PSR-2`: http://www.php-fig.org/psr/psr-2/

Diff for: contributing/community/releases.rst

-1
Original file line numberDiff line numberDiff line change
@@ -161,5 +161,4 @@ upgrade.
161161

162162
.. _Git repository: https://github.com/symfony/symfony
163163
.. _SensioLabs: http://sensiolabs.com/
164-
.. _roadmap: http://symfony.com/roadmap
165164
.. _`timeline calculator`: http://symfony.com/roadmap

Diff for: cookbook/assetic/apply_to_option.rst

+2-2
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ An example configuration might look like this:
2828
2929
<!-- app/config/config.xml -->
3030
<assetic:config>
31-
<assetic:filter
31+
<assetic:filter
3232
name="coffee"
3333
bin="/usr/bin/coffee/"
3434
node="/usr/bin/node/">
@@ -72,7 +72,7 @@ templates:
7272
<script src="<?php echo $view->escape($url) ?>" type="text/javascript"></script>
7373
<?php endforeach; ?>
7474

75-
This is all that's needed to compile this CoffeeScript file and server it
75+
This is all that's needed to compile this CoffeeScript file and serve it
7676
as the compiled JavaScript.
7777

7878
Filter Multiple Files

Diff for: cookbook/assetic/asset_management.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -255,7 +255,7 @@ In fact, Assetic has a long list of available filters.
255255

256256
Many of the filters do not do the work directly, but use existing third-party
257257
libraries to do the heavy-lifting. This means that you'll often need to install
258-
a third-party library to use a filter. The great advantage of using Assetic
258+
a third-party library to use a filter. The great advantage of using Assetic
259259
to invoke these libraries (as opposed to using them directly) is that instead
260260
of having to run them manually after you work on the files, Assetic will
261261
take care of this for you and remove this step altogether from your development

Diff for: cookbook/bundles/best_practices.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -284,4 +284,4 @@ Learn more from the Cookbook
284284

285285
* :doc:`/cookbook/bundles/extension`
286286

287-
.. _standards: http://symfony.com/PSR0
287+
.. _standards: http://www.php-fig.org/psr/psr-0/

Diff for: cookbook/bundles/extension.rst

+2-2
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ When you create a bundle, you have two choices on how to handle configuration:
6262
The second option - which you'll learn about in this article - is much more
6363
flexible, but also requires more time to setup. If you're wondering which
6464
method you should use, it's probably a good idea to start with method #1,
65-
and then change to #2 later if you need to. If you plan to distribute your
65+
and then change to #2 later if you need to. If you plan to distribute your
6666
bundle, the second option is recommended.
6767

6868
The second method has several specific advantages:
@@ -519,7 +519,7 @@ be output to the console in YAML.
519519

520520
As long as your bundle's configuration is located in the standard location
521521
(``YourBundle\DependencyInjection\Configuration``) and does not have a
522-
``__construct()`` it will work automatically. If you have something
522+
``__construct()`` it will work automatically. If you have something
523523
different, your ``Extension`` class must override the
524524
:method:`Extension::getConfiguration() <Symfony\\Component\\HttpKernel\\DependencyInjection\\Extension::getConfiguration>`
525525
method and return an instance of your

Diff for: cookbook/bundles/remove.rst

+2-2
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ the name of the bundle is, e.g. ``fos_user`` for the FOSUserBundle) string in
6262
the configuration files.
6363

6464
The AcmeDemoBundle doesn't have configuration. However, the bundle is
65-
used in the configuration for the ``app/config/security.yml`` file. You can
65+
used in the configuration for the ``app/config/security.yml`` file. You can
6666
use it as a boilerplate for your own security, but you **can** also remove
6767
everything: it doesn't matter to Symfony if you remove it or not.
6868

@@ -103,4 +103,4 @@ rely on the bundle you are about to remove.
103103
.. tip::
104104

105105
If a third party bundle relies on another bundle, you can find that bundle
106-
mentioned in the ``composer.json`` file included in the bundle directory.
106+
mentioned in the ``composer.json`` file included in the bundle directory.

Diff for: cookbook/configuration/environments.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ multiple environments in an elegant, powerful and transparent way.
5555

5656
Of course, in reality, each environment differs only somewhat from others.
5757
Generally, all environments will share a large base of common configuration.
58-
Opening the "dev" configuration file, you can see how this is accomplished
58+
Opening the "dev" configuration file, you can see how this is accomplished
5959
easily and transparently:
6060

6161
.. configuration-block::

Diff for: cookbook/configuration/external_parameters.rst

+2-2
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ Environment Variables
1414
---------------------
1515

1616
Symfony will grab any environment variable prefixed with ``SYMFONY__`` and
17-
set it as a parameter in the service container. Double underscores are replaced
17+
set it as a parameter in the service container. Double underscores are replaced
1818
with a period, as a period is not a valid character in an environment variable
1919
name.
2020

@@ -39,7 +39,7 @@ the following ``VirtualHost`` configuration:
3939
.. note::
4040

4141
The example above is for an Apache configuration, using the `SetEnv`_
42-
directive. However, this will work for any web server which supports
42+
directive. However, this will work for any web server which supports
4343
the setting of environment variables.
4444

4545
Also, in order for your console to work (which does not use Apache),

Diff for: cookbook/configuration/front_controllers_and_kernel.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ Understanding how the Front Controller, Kernel and Environments work together
77

88
The section :doc:`/cookbook/configuration/environments` explained the basics
99
on how Symfony uses environments to run your application with different configuration
10-
settings. This section will explain a bit more in-depth what happens when
10+
settings. This section will explain a bit more in-depth what happens when
1111
your application is bootstrapped. To hook into this process, you need to understand
1212
three parts that work together:
1313

Diff for: cookbook/configuration/web_server_configuration.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ following configuration snippet:
4848

4949
.. code-block:: apache
5050
51-
RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}]
51+
RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}]
5252
5353
.. caution::
5454

Diff for: cookbook/console/logging.rst

+1-2
Original file line numberDiff line numberDiff line change
@@ -55,8 +55,7 @@ container and use it to do the logging::
5555
if ($input->getOption('yell')) {
5656
$text = strtoupper($text);
5757
$logger->warn('Yelled: '.$text);
58-
}
59-
else {
58+
} else {
6059
$logger->info('Greeted: '.$text);
6160
}
6261

0 commit comments

Comments
 (0)