Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commita2817c6

Browse files
committed
Merge branch '2.3' into 2.4
2 parentsb7ac326 +a21fb26 commita2817c6

File tree

25 files changed

+169
-65
lines changed

25 files changed

+169
-65
lines changed

‎README.markdown

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,9 @@ Contributing
77
------------
88

99
>**Note**
10-
>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,
12-
>**not** the master or2.3 branch.
10+
>Unless you're documenting a feature that was introduced*after* Symfony 2.3
11+
>(e.g.inSymfony 2.4), all pull requests must be based off of the**2.3** branch,
12+
>**not** the master orolder branches.
1313
1414
We love contributors! For more information on how you can contribute to the
1515
Symfony documentation, please read

‎book/controller.rst

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -513,7 +513,10 @@ value to each variable.
513513
$subRequest = $request->duplicate(array(), null, $path);
514514

515515
$httpKernel = $this->container->get('http_kernel');
516-
$response = $httpKernel->handle($subRequest, HttpKernelInterface::SUB_REQUEST);
516+
$response = $httpKernel->handle(
517+
$subRequest,
518+
HttpKernelInterface::SUB_REQUEST
519+
);
517520

518521
..index::
519522
single: Controller; Rendering templates
@@ -579,7 +582,8 @@ The Symfony templating engine is explained in great detail in the
579582
'AcmeHelloBundle:Hello/Greetings:index.html.twig',
580583
array('name' => $name)
581584
);
582-
// index.html.twig found in Resources/views/Hello/Greetings is rendered.
585+
// index.html.twig found in Resources/views/Hello/Greetings
586+
// is rendered.
583587

584588
..index::
585589
single: Controller; Accessing services

‎book/doctrine.rst

Lines changed: 17 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -623,7 +623,9 @@ You can also take advantage of the useful ``findBy`` and ``findOneBy`` methods
623623
to easily fetch objects based on multiple conditions::
624624

625625
// query for one product matching be name and price
626-
$product = $repository->findOneBy(array('name' => 'foo', 'price' => 19.99));
626+
$product = $repository->findOneBy(
627+
array('name' => 'foo', 'price' => 19.99)
628+
);
627629

628630
// query for all products matching the name, ordered by price
629631
$products = $repository->findBy(
@@ -1144,7 +1146,8 @@ Now you can see this new code in action! Imagine you're inside a controller::
11441146
$em->flush();
11451147

11461148
return new Response(
1147-
'Created product id: '.$product->getId().' and category id: '.$category->getId()
1149+
'Created product id: '.$product->getId()
1150+
.' and category id: '.$category->getId()
11481151
);
11491152
}
11501153
}
@@ -1253,8 +1256,8 @@ following method to the ``ProductRepository`` class::
12531256
public function findOneByIdJoinedToCategory($id)
12541257
{
12551258
$query = $this->getEntityManager()
1256-
->createQuery('
1257-
SELECT p, c FROM AcmeStoreBundle:Product p
1259+
->createQuery(
1260+
'SELECT p, c FROM AcmeStoreBundle:Product p
12581261
JOIN p.category c
12591262
WHERE p.id = :id'
12601263
)->setParameter('id', $id);
@@ -1478,8 +1481,8 @@ and ``nullable``. Take a few examples:
14781481
protected $name;
14791482
14801483
/**
1481-
* A string field of length 150 that persists to an "email_address" column
1482-
* and has a unique index.
1484+
* A string field of length 150 that persists to an
1485+
*"email_address" columnand has a unique index.
14831486
*
14841487
* @ORM\Column(name="email_address", unique=true, length=150)
14851488
*/
@@ -1489,13 +1492,14 @@ and ``nullable``. Take a few examples:
14891492
14901493
fields:
14911494
# A string field length 255 that cannot be null
1492-
# (reflecting the default values for the "length" and *nullable* options)
1493-
# type attribute is necessary in YAML definitions
1495+
# (reflecting the default values for the "length"
1496+
# and *nullable* options) type attribute is
1497+
# necessary in YAML definitions
14941498
name:
14951499
type:string
14961500
1497-
# A string field of length 150 that persists to an "email_address" column
1498-
# and has a unique index.
1501+
# A string field of length 150 that persists to
1502+
#an "email_address" columnand has a unique index.
14991503
email:
15001504
type:string
15011505
column:email_address
@@ -1506,8 +1510,9 @@ and ``nullable``. Take a few examples:
15061510
15071511
<!--
15081512
A string field length 255 that cannot be null
1509-
(reflecting the default values for the "length" and *nullable* options)
1510-
type attribute is necessary in XML definitions
1513+
(reflecting the default values for the "length"
1514+
and *nullable* options) type attribute is
1515+
necessary in XML definitions
15111516
-->
15121517
<fieldname="name"type="string" />
15131518
<fieldname="email"

‎book/forms.rst

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -645,7 +645,8 @@ the documentation for each type.
645645
))
646646

647647
The label for a field can also be set in the template rendering the
648-
form, see below.
648+
form, see below. If you don't need a label associated to your input,
649+
you can disable it by setting its value to ``false``.
649650

650651
..index::
651652
single: Forms; Field type guessing

‎changelog.rst

Lines changed: 66 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,66 @@
1+
..index::
2+
single: CHANGELOG
3+
4+
The Documentation Changelog
5+
===========================
6+
7+
This documentation is always changing: All new features need new documentation
8+
and bugs/typos get fixed. This article holds all important changes of the
9+
documentation.
10+
11+
..tip::
12+
13+
Do you also want to participate in the Symfony Documentation? Take a look
14+
at the ":doc:`/contributing/documentation`" article.
15+
16+
January, 2014
17+
-------------
18+
19+
New Documentation
20+
~~~~~~~~~~~~~~~~~
21+
22+
No changes
23+
24+
Fixed Documentation
25+
~~~~~~~~~~~~~~~~~~~
26+
27+
- `e385d28<https://github.com/symfony/symfony-docs/commit/e385d28bee7c7418c8175d43befc4954a43a300c>`_ #3503 file extension correction xfliff to xliff (nixilla)
28+
- `7fe0de3<https://github.com/symfony/symfony-docs/commit/7fe0de330b2d72155b6b7ec87c59f5a7e7ee4881>`_ #3475 Fixed doc for framework.session.cookie_lifetime refrence. (tyomo4ka)
29+
- `8155e4c<https://github.com/symfony/symfony-docs/commit/8155e4cab70e481962a4775274a4412a4465ecdc>`_ #3473 Update proxy_examples.rst (AZielinski)
30+
- `c205bc6<https://github.com/symfony/symfony-docs/commit/c205bc6798bac34741f2d4d91450aac75ab14b93>`_ #3468 enclose YAML string with double quotes to fix syntax highlighting (xabbuh)
31+
- `89963cc<https://github.com/symfony/symfony-docs/commit/89963cc246263e7e7cdecd3cad1f019ff9cb28a5>`_ #3463 Fix typos in cookbook/testing/database (ifdattic)
32+
- `e0a52ec<https://github.com/symfony/symfony-docs/commit/e0a52ecf0cbcf1b5aa029f323588880080f5c6f3>`_ #3460 remove confusing outdated note on interactive rebasing (xabbuh)
33+
- `6831b13<https://github.com/symfony/symfony-docs/commit/6831b1337f99c26d9f04eb82990cc3b3ac128de0>`_ #3455 [Contributing][Code] fix indentation so that the text is rendered properly (xabbuh)
34+
- `ea5816f<https://github.com/symfony/symfony-docs/commit/ea5816f571309decd946bf30aa0b3b84fffacb9e>`_ #3433 [WIP][Reference][Form Types] Update "radio" form type (bicpi)
35+
- `42c80d1<https://github.com/symfony/symfony-docs/commit/42c80d12ac760f40834afef76fd42db83d4d4a33>`_ #3448 Overridden tweak (weaverryan)
36+
- `d9d7c58<https://github.com/symfony/symfony-docs/commit/d9d7c58ca41ae370545ae25f13857780c089f970>`_ #3444 Fix issue #3442 (ifdattic)
37+
- `9e2e64b<https://github.com/symfony/symfony-docs/commit/9e2e64b26a355416038b632b7eec89c7c14490cb>`_ #3427 Removed code references to Symfony Standard Distribution (danielcsgomes)
38+
- `26b8146<https://github.com/symfony/symfony-docs/commit/26b8146188a3f8bedf2e681d40509b418c8e7ec0>`_ #3415 [#3334] the data_class option was not introduced in 2.4 (xabbuh)
39+
- `0b2a491<https://github.com/symfony/symfony-docs/commit/0b2a49199752f60aa1bcc16d48f4c558160e852e>`_ #3414 add missing code-block directive (xabbuh)
40+
- `4988118<https://github.com/symfony/symfony-docs/commit/4988118e127dc51d73e2518982c0a0f4ca9206f1>`_ #3432 [Reference][Form Types] Add "max_length" option in form type (nykopol)
41+
- `26a7b1b<https://github.com/symfony/symfony-docs/commit/26a7b1b80aa654c9293599743f9c0a38054eb4d3>`_ #3423 [Session Configuration] add clarifying notes on session save handler proxies (cordoval)
42+
43+
Minor Documentation Changes
44+
~~~~~~~~~~~~~~~~~~~~~~~~~~~
45+
46+
- `1131247<https://github.com/symfony/symfony-docs/commit/11312477437e5367da466727acdc89c97b8ed73a>`_ #3508 Add 'in XML' for additional clarity (ifdattic)
47+
- `a650b93<https://github.com/symfony/symfony-docs/commit/a650b9364297aa5eaa5ffd3c018b3f0858d12238>`_ #3506 Nykopol overriden options (weaverryan)
48+
- `ab10035<https://github.com/symfony/symfony-docs/commit/ab1003501de3e81bc48226b32b53156e2e7a573a>`_ #3505 replace Akamaï with Akamai (xabbuh)
49+
- `7f56c20<https://github.com/symfony/symfony-docs/commit/7f56c201ea4cd9b1e7b7ed36ceb2046352a143f2>`_ #3501 [Security] Fix markup (tyx)
50+
- `80a90ba<https://github.com/symfony/symfony-docs/commit/80a90ba8b5c2eceeb2d80bb1386fb2620b8e0c6e>`_ #3500 Minimize horizontal scrolling in code blocks (improve readability) (ifdattic)
51+
- `e5bc4ea<https://github.com/symfony/symfony-docs/commit/e5bc4eafeab96b8b12070ce0435b8a77ee85c6c1>`_ #3498 Remove second empty data (xabbuh)
52+
- `d084d87<https://github.com/symfony/symfony-docs/commit/d084d876e3ab961c92f2753c73b0a73a75ee7a8b>`_ #3485 [Cookbook][Assetic] Fix "javascripts" tag name typo (bicpi)
53+
- `3250aba<https://github.com/symfony/symfony-docs/commit/3250aba13ccf8662aa8e38cb624b3adeab0944bc>`_ #3481 Fix code block (minimise horizontal scrolling), typo in yaml (ifdattic)
54+
- `f285d93<https://github.com/symfony/symfony-docs/commit/f285d930377d8cbaedccc3ad46853fa72ee6439d>`_ #3451 some language tweaks (AE, third-person perspective) (xabbuh)
55+
- `2b7e0f6<https://github.com/symfony/symfony-docs/commit/2b7e0f6f2f9982e600918f447852a6f4c60966a1>`_ #3497 Fix highlighting (WouterJ)
56+
- `a535ae0<https://github.com/symfony/symfony-docs/commit/a535ae0383a2a6715021681980877b0205dc3281>`_ #3471 Fixed `````versionadded````` inconsistencies in Symfony 2.3 (danielcsgomes)
57+
- `f077a8e<https://github.com/symfony/symfony-docs/commit/f077a8e71c4973e7775db8c9fb548a0866d21131>`_ #3465 change wording in versionadded example to be consistent with what we use... (xabbuh)
58+
- `f9f7548<https://github.com/symfony/symfony-docs/commit/f9f7548c7a53e62564b30d7e945a9b52b3f358db>`_ #3462 Replace ... with etc (ifdattic)
59+
- `65efcc4<https://github.com/symfony/symfony-docs/commit/65efcc4f64365acf5895597bb32e9b611f9bbfcd>`_ #3445 [Reference][Form Types] Add missing (but existing) options to "form" type (bicpi)
60+
- `1d1b91d<https://github.com/symfony/symfony-docs/commit/1d1b91d6cbd4479e85ff2fdbc2cbab4f7a9a778b>`_ #3431 [Config] add cautionary note on ini file loader limitation (cordoval)
61+
- `f2eaf9b<https://github.com/symfony/symfony-docs/commit/f2eaf9bbc5d3a73c83ef6e4ce1830bd3e277dcc0>`_ #3419 doctrine file upload example uses dir -- caution added (cordoval)
62+
- `72b53ad<https://github.com/symfony/symfony-docs/commit/72b53ad4312f74920568e39ebbddc2b3b8008797>`_ #3404 [#3276] Trying to further clarify the session storage directory details (weaverryan)
63+
- `67b7bbd<https://github.com/symfony/symfony-docs/commit/67b7bbda858337555b7404a17e6ead20d2144eff>`_ #3413 [Cookbook][Bundles] improve explanation of code block for bundle removal (cordoval)
64+
- `7c5a914<https://github.com/symfony/symfony-docs/commit/7c5a9141d6dd716e692b27904190225be324f332>`_ #3369 Indicate that Group Sequence Providers can use YAML (karptonite)
65+
- `1e0311e<https://github.com/symfony/symfony-docs/commit/1e0311ef0124fda8ad0cb07f73a3a52ce3303f2b>`_ #3416 add empty_data option where required option is used (xabbuh)
66+
- `2be3f52<https://github.com/symfony/symfony-docs/commit/2be3f52cf5178606e54826e0766f31ce110ee122>`_ #3422 [Cookbook][Custom Authentication Provider] add a note of warning for when forbidding anonymous users (cordoval)

‎components/dependency_injection/parameters.rst

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,13 @@ and set a parameter in the container with::
2525

2626
$container->setParameter('mailer.transport', 'sendmail');
2727

28+
..caution::
29+
30+
The used ``.`` notation is just a
31+
:ref:`Symfony convention<service-naming-conventions>` to make parameters
32+
easier to read. Parameters are just flat key-value elements, they can't be
33+
organized into a nested array
34+
2835
..note::
2936

3037
You can only set a parameter before the container is compiled. To learn
@@ -190,9 +197,9 @@ making the class of a service a parameter:
190197
Array Parameters
191198
----------------
192199

193-
Parameters do not need to be flat strings, they can alsobe arrays. For the XML
194-
format, you need to use the ``type="collection"`` attribute for all parameters that are
195-
arrays.
200+
Parameters do not need to be flat strings, they can alsocontain array values.
201+
For the XMLformat, you need to use the ``type="collection"`` attribute for
202+
all parameters that arearrays.
196203

197204
..configuration-block::
198205

‎components/event_dispatcher/generic_event.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ Filtering data::
9393

9494
use Symfony\Component\EventDispatcher\GenericEvent;
9595

96-
$event = new GenericEvent($subject, array('data' => 'foo'));
96+
$event = new GenericEvent($subject, array('data' => 'Foo'));
9797
$dispatcher->dispatch('foo', $event);
9898

9999
echo $event['data'];
@@ -102,6 +102,6 @@ Filtering data::
102102
{
103103
public function filter(GenericEvent $event)
104104
{
105-
strtolower($event['data']);
105+
$event['data'] =strtolower($event['data']);
106106
}
107107
}

‎components/form/introduction.rst

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -181,8 +181,10 @@ to bootstrap or access Twig and add the :class:`Symfony\\Bridge\\Twig\\Extension
181181
$defaultFormTheme = 'form_div_layout.html.twig';
182182

183183
$vendorDir = realpath(__DIR__ . '/../vendor');
184-
// the path to TwigBridge so Twig can locate the form_div_layout.html.twig file
185-
$vendorTwigBridgeDir = $vendorDir . '/symfony/twig-bridge/Symfony/Bridge/Twig';
184+
// the path to TwigBridge so Twig can locate the
185+
// form_div_layout.html.twig file
186+
$vendorTwigBridgeDir =
187+
$vendorDir . '/symfony/twig-bridge/Symfony/Bridge/Twig';
186188
// the path to your other templates
187189
$viewsDir = realpath(__DIR__ . '/../views');
188190

@@ -193,7 +195,9 @@ to bootstrap or access Twig and add the :class:`Symfony\\Bridge\\Twig\\Extension
193195
$formEngine = new TwigRendererEngine(array($defaultFormTheme));
194196
$formEngine->setEnvironment($twig);
195197
// add the FormExtension to Twig
196-
$twig->addExtension(new FormExtension(new TwigRenderer($formEngine, $csrfProvider)));
198+
$twig->addExtension(
199+
new FormExtension(new TwigRenderer($formEngine, $csrfProvider))
200+
);
197201

198202
// create your form factory as normal
199203
$formFactory = Forms::createFormFactoryBuilder()
@@ -307,7 +311,8 @@ Your integration with the Validation component will look something like this::
307311

308312
$vendorDir = realpath(__DIR__ . '/../vendor');
309313
$vendorFormDir = $vendorDir . '/symfony/form/Symfony/Component/Form';
310-
$vendorValidatorDir = $vendorDir . '/symfony/validator/Symfony/Component/Validator';
314+
$vendorValidatorDir =
315+
$vendorDir . '/symfony/validator/Symfony/Component/Validator';
311316

312317
// create the validator - details will vary
313318
$validator = Validation::createValidator();

‎components/http_foundation/introduction.rst

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -265,7 +265,8 @@ If you need to get full access to parsed data from ``Accept``, ``Accept-Language
265265
}
266266

267267
// accepts items are sorted by descending quality
268-
$accepts = AcceptHeader::fromString($request->headers->get('Accept'))->all();
268+
$accepts = AcceptHeader::fromString($request->headers->get('Accept'))
269+
->all();
269270

270271
Accessing other Data
271272
~~~~~~~~~~~~~~~~~~~~
@@ -477,7 +478,10 @@ abstracts the hard work behind a simple API::
477478

478479
use Symfony\Component\HttpFoundation\ResponseHeaderBag;
479480

480-
$d = $response->headers->makeDisposition(ResponseHeaderBag::DISPOSITION_ATTACHMENT, 'foo.pdf');
481+
$d = $response->headers->makeDisposition(
482+
ResponseHeaderBag::DISPOSITION_ATTACHMENT,
483+
'foo.pdf'
484+
);
481485

482486
$response->headers->set('Content-Disposition', $d);
483487

@@ -505,7 +509,10 @@ if it should::
505509
You can still set the ``Content-Type`` of the sent file, or change its ``Content-Disposition``::
506510

507511
$response->headers->set('Content-Type', 'text/plain');
508-
$response->setContentDisposition(ResponseHeaderBag::DISPOSITION_ATTACHMENT, 'filename.txt');
512+
$response->setContentDisposition(
513+
ResponseHeaderBag::DISPOSITION_ATTACHMENT,
514+
'filename.txt'
515+
);
509516

510517
.. _component-http-foundation-json-response:
511518

‎components/http_foundation/sessions.rst

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ Quick example::
2828

2929
// retrieve messages
3030
foreach ($session->getFlashBag()->get('notice', array()) as $message) {
31-
echo"<div class='flash-notice'>$message</div>";
31+
echo'<div class="flash-notice">'.$message.'</div>';
3232
}
3333

3434
..note::
@@ -254,7 +254,7 @@ has a simple API
254254
Adds a flash message to the stack of specified type;
255255

256256
*:method:`Symfony\\Component\\HttpFoundation\\Session\\Flash\\FlashBagInterface::set`:
257-
Sets flashes by type; This method conveniently takes bothsingles messages as
257+
Sets flashes by type; This method conveniently takes bothsingle messages as
258258
a ``string`` or multiple messages in an ``array``.
259259

260260
*:method:`Symfony\\Component\\HttpFoundation\\Session\\Flash\\FlashBagInterface::get`:
@@ -308,18 +308,18 @@ Simple, display one type of message::
308308

309309
// display warnings
310310
foreach ($session->getFlashBag()->get('warning', array()) as $message) {
311-
echo"<div class='flash-warning'>$message</div>";
311+
echo'<div class="flash-warning">'.$message.'</div>';
312312
}
313313

314314
// display errors
315315
foreach ($session->getFlashBag()->get('error', array()) as $message) {
316-
echo"<div class='flash-error'>$message</div>";
316+
echo'<div class="flash-error">'.$message.'</div>';
317317
}
318318

319319
Compact method to process display all flashes at once::
320320

321321
foreach ($session->getFlashBag()->all() as $type => $messages) {
322322
foreach ($messages as $message) {
323-
echo"<div class='flash-$type'>$message</div>\n";
323+
echo'<div class="flash-'.$type.'">'.$message.'</div>';
324324
}
325325
}

‎components/http_kernel/introduction.rst

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -603,6 +603,7 @@ a built-in ControllerResolver that can be used to create a working example::
603603
use Symfony\Component\HttpKernel\HttpKernel;
604604
use Symfony\Component\EventDispatcher\EventDispatcher;
605605
use Symfony\Component\HttpKernel\Controller\ControllerResolver;
606+
use Symfony\Component\HttpKernel\EventListener\RouterListener;
606607
use Symfony\Component\Routing\RouteCollection;
607608
use Symfony\Component\Routing\Route;
608609
use Symfony\Component\Routing\Matcher\UrlMatcher;
@@ -611,7 +612,9 @@ a built-in ControllerResolver that can be used to create a working example::
611612
$routes = new RouteCollection();
612613
$routes->add('hello', new Route('/hello/{name}', array(
613614
'_controller' => function (Request $request) {
614-
return new Response(sprintf("Hello %s", $request->get('name')));
615+
return new Response(
616+
sprintf("Hello %s", $request->get('name'))
617+
);
615618
}
616619
)
617620
));
@@ -647,7 +650,7 @@ your controller).
647650
:align:center
648651

649652
To execute a sub request, use ``HttpKernel::handle``, but change the second
650-
arguments as follows::
653+
argument as follows::
651654

652655
use Symfony\Component\HttpFoundation\Request;
653656
use Symfony\Component\HttpKernel\HttpKernelInterface;

‎components/intl.rst

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ code::
7878

7979
These versions are important when you deploy your application to a **server with
8080
a lower ICU version** than your development machines, because deployment will
81-
fail if
81+
fail if:
8282

8383
* the development machines are compiled with ICU 4.4 or higher, but the
8484
server is compiled with a lower ICU version than 4.4;
@@ -282,7 +282,12 @@ multi-valued entries (arrays), the values of the more specific and the fallback
282282
locale will be merged. In order to suppress this behavior, the last parameter
283283
``$fallback`` can be set to ``false``::
284284

285-
echo $reader->readEntry('/path/to/bundle', 'en', array('Data', 'entry1'), false);
285+
echo $reader->readEntry(
286+
'/path/to/bundle',
287+
'en',
288+
array('Data', 'entry1'),
289+
false
290+
);
286291

287292
Accessing ICU Data
288293
------------------

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp