Skip to content

Commit 989e5ea

Browse files
committed
Merge branch '2.7' into 2.8
* 2.7: incorrect session short description Use of Setters and Getters Small mistype edits Changed text how to get button label Small misspelling fixes Small typo fix Edited to show more ways, to get crawler form Fix (sense) typo in ACL documentation
2 parents f45161c + da6afe8 commit 989e5ea

File tree

4 files changed

+15
-6
lines changed

4 files changed

+15
-6
lines changed

components/dom_crawler.rst

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -325,10 +325,19 @@ given text. This method is especially useful because you can use it to return
325325
a :class:`Symfony\\Component\\DomCrawler\\Form` object that represents the
326326
form that the button lives in::
327327

328-
$form = $crawler->selectButton('validate')->form();
328+
// button example: <button id="my-super-button" type="submit">My super button</button>
329+
330+
// you can get button by its label
331+
$form = $crawler->selectButton('My super button')->form();
332+
333+
// or by button id (#my-super-button) if the button doesn't have a label
334+
$form = $crawler->selectButton('my-super-button')->form();
335+
336+
// or you can filter the whole form, for example a form has a class attribute: <form class="form-vertical" method="POST">
337+
$crawler->filter('.form-vertical')->form();
329338

330339
// or "fill" the form fields with data
331-
$form = $crawler->selectButton('validate')->form(array(
340+
$form = $crawler->selectButton('my-super-button')->form(array(
332341
'name' => 'Ryan',
333342
));
334343

controller.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -349,8 +349,8 @@ Managing the Session
349349
--------------------
350350

351351
Symfony provides a nice session object that you can use to store information
352-
about the user between requests. By default, Symfony stores the attributes in a
353-
cookie by using native PHP sessions.
352+
about the user between requests. By default, Symfony stores the token in a
353+
cookie and writes the attributes to a file by using native PHP sessions.
354354

355355
To retrieve the session, call
356356
:method:`Symfony\\Bundle\\FrameworkBundle\\Controller\\Controller::getSession`

controller/upload_file.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -239,7 +239,7 @@ logic to a separate service::
239239
{
240240
$fileName = md5(uniqid()).'.'.$file->guessExtension();
241241

242-
$file->move($this->targetDir, $fileName);
242+
$file->move($this->getTargetDir(), $fileName);
243243

244244
return $fileName;
245245
}

security/acl_advanced.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -190,7 +190,7 @@ this request to an implementation of
190190
This allows you to replace the way access decisions are reached without actually
191191
modifying the ACL class itself.
192192

193-
The ``PermissionGrantingStrategy`` first checks all your object-scope ACEs. If none
193+
The ``PermissionGrantingStrategy`` first checks all your object-scope ACEs. If one
194194
is applicable, the class-scope ACEs will be checked. If none is applicable,
195195
then the process will be repeated with the ACEs of the parent ACL. If no
196196
parent ACL exists, an exception will be thrown.

0 commit comments

Comments
 (0)