Skip to content

Commit 83696b8

Browse files
committed
minor #4934 Fixes for 2.3 branch (ifdattic)
This PR was merged into the 2.3 branch. Discussion ---------- Fixes for 2.3 branch | Q | A | ------------- | --- | Doc fix? | yes | New docs? | no | Applies to | 2.3 | Fixed tickets | Commits ------- 611a011 Fix typos 3fe41fd Misc changes 3f24f8e Fix typo b04f311 Fix typos a21042c Fix typo
2 parents 99d225b + 611a011 commit 83696b8

File tree

5 files changed

+24
-18
lines changed

5 files changed

+24
-18
lines changed

components/finder.rst

+2-1
Original file line numberDiff line numberDiff line change
@@ -308,7 +308,8 @@ The contents of returned files can be read with
308308

309309
foreach ($finder as $file) {
310310
$contents = $file->getContents();
311-
...
311+
312+
// ...
312313
}
313314

314315
.. _strtotime: http://www.php.net/manual/en/datetime.formats.php

components/form/form_events.rst

+5-2
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,7 @@ The ``FormEvents::PRE_SUBMIT`` event is dispatched at the beginning of the
131131

132132
It can be used to:
133133

134-
* Change data from the request, before submitting the data to the form.
134+
* Change data from the request, before submitting the data to the form;
135135
* Add or remove form fields, before submitting the data to the form.
136136

137137
:ref:`Form Events Information Table<component-form-event-table>`
@@ -303,7 +303,10 @@ callback for better readability::
303303
{
304304
$builder->add('username', 'text');
305305
$builder->add('show_email', 'checkbox');
306-
$builder->addEventListener(FormEvents::PRE_SET_DATA, array($this, 'onPreSetData'));
306+
$builder->addEventListener(
307+
FormEvents::PRE_SET_DATA,
308+
array($this, 'onPreSetData')
309+
);
307310
}
308311

309312
public function onPreSetData(FormEvent $event)

components/form/introduction.rst

+13-11
Original file line numberDiff line numberDiff line change
@@ -186,17 +186,17 @@ to bootstrap or access Twig and add the :class:`Symfony\\Bridge\\Twig\\Extension
186186
// this file comes with TwigBridge
187187
$defaultFormTheme = 'form_div_layout.html.twig';
188188

189-
$vendorDir = realpath(__DIR__ . '/../vendor');
189+
$vendorDir = realpath(__DIR__.'/../vendor');
190190
// the path to TwigBridge so Twig can locate the
191191
// form_div_layout.html.twig file
192192
$vendorTwigBridgeDir =
193-
$vendorDir . '/symfony/twig-bridge/Symfony/Bridge/Twig';
193+
$vendorDir.'/symfony/twig-bridge/Symfony/Bridge/Twig';
194194
// the path to your other templates
195-
$viewsDir = realpath(__DIR__ . '/../views');
195+
$viewsDir = realpath(__DIR__.'/../views');
196196

197197
$twig = new Twig_Environment(new Twig_Loader_Filesystem(array(
198198
$viewsDir,
199-
$vendorTwigBridgeDir . '/Resources/views/Form',
199+
$vendorTwigBridgeDir.'/Resources/views/Form',
200200
)));
201201
$formEngine = new TwigRendererEngine(array($defaultFormTheme));
202202
$formEngine->setEnvironment($twig);
@@ -315,24 +315,24 @@ Your integration with the Validation component will look something like this::
315315
use Symfony\Component\Form\Extension\Validator\ValidatorExtension;
316316
use Symfony\Component\Validator\Validation;
317317

318-
$vendorDir = realpath(__DIR__ . '/../vendor');
319-
$vendorFormDir = $vendorDir . '/symfony/form/Symfony/Component/Form';
318+
$vendorDir = realpath(__DIR__.'/../vendor');
319+
$vendorFormDir = $vendorDir.'/symfony/form/Symfony/Component/Form';
320320
$vendorValidatorDir =
321-
$vendorDir . '/symfony/validator/Symfony/Component/Validator';
321+
$vendorDir.'/symfony/validator/Symfony/Component/Validator';
322322

323323
// create the validator - details will vary
324324
$validator = Validation::createValidator();
325325

326326
// there are built-in translations for the core error messages
327327
$translator->addResource(
328328
'xlf',
329-
$vendorFormDir . '/Resources/translations/validators.en.xlf',
329+
$vendorFormDir.'/Resources/translations/validators.en.xlf',
330330
'en',
331331
'validators'
332332
);
333333
$translator->addResource(
334334
'xlf',
335-
$vendorValidatorDir . '/Resources/translations/validators.en.xlf',
335+
$vendorValidatorDir.'/Resources/translations/validators.en.xlf',
336336
'en',
337337
'validators'
338338
);
@@ -671,10 +671,12 @@ object::
671671

672672
// ...
673673

674-
// an array of FormError objects, but only errors attached to this form level (e.g. "global errors)
674+
// an array of FormError objects, but only errors attached to this
675+
// form level (e.g. "global errors)
675676
$errors = $form->getErrors();
676677

677-
// an array of FormError objects, but only errors attached to the "firstName" field
678+
// an array of FormError objects, but only errors attached to the
679+
// "firstName" field
678680
$errors = $form['firstName']->getErrors();
679681

680682
// a string representation of all errors of the whole form tree

components/form/type_guesser.rst

+2-2
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ Start by creating the class and these methods. Next, you'll learn how to fill ea
4646
4747
use Symfony\Component\Form\FormTypeGuesserInterface;
4848
49-
class PhpdocTypeGuesser implements FormTypeGuesserInterface
49+
class PHPDocTypeGuesser implements FormTypeGuesserInterface
5050
{
5151
public function guessType($class, $property)
5252
{
@@ -92,7 +92,7 @@ With this knowledge, you can easily implement the ``guessType`` method of the
9292
use Symfony\Component\Form\Guess\Guess;
9393
use Symfony\Component\Form\Guess\TypeGuess;
9494

95-
class PhpdocTypeGuesser implements FormTypeGuesserInterface
95+
class PHPDocTypeGuesser implements FormTypeGuesserInterface
9696
{
9797
public function guessType($class, $property)
9898
{

components/process.rst

+2-2
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,7 @@ Stopping a Process
117117

118118
Any asynchronous process can be stopped at any time with the
119119
:method:`Symfony\\Component\\Process\\Process::stop` method. This method takes
120-
two arguments : a timeout and a signal. Once the timeout is reached, the signal
120+
two arguments: a timeout and a signal. Once the timeout is reached, the signal
121121
is sent to the running process. The default signal sent to a process is ``SIGKILL``.
122122
Please read the :ref:`signal documentation below<reference-process-signal>`
123123
to find out more about signal handling in the Process component::
@@ -217,7 +217,7 @@ Process Signals
217217
.. versionadded:: 2.3
218218
The ``signal`` method was introduced in Symfony 2.3.
219219

220-
When running a program asynchronously, you can send it posix signals with the
220+
When running a program asynchronously, you can send it POSIX signals with the
221221
:method:`Symfony\\Component\\Process\\Process::signal` method::
222222

223223
use Symfony\Component\Process\Process;

0 commit comments

Comments
 (0)