Skip to content

Commit

Permalink
Merge branch '2.7' into 2.8
Browse files Browse the repository at this point in the history
  • Loading branch information
wouterj committed Dec 18, 2015
2 parents a5114d2 + d782c4b commit b2b1239
Show file tree
Hide file tree
Showing 13 changed files with 196 additions and 189 deletions.
6 changes: 6 additions & 0 deletions best_practices/creating-the-project.rst
Expand Up @@ -35,6 +35,11 @@ to create files and execute the following commands:
c:\> cd projects/
c:\projects\> php symfony new blog
.. note::

If the installer doesn't work for you or doesn't output anything, make sure
that the `Phar extension`_ is installed and enabled on your computer.

This command creates a new directory called ``blog`` that contains a fresh new
project based on the most recent stable Symfony version available. In addition,
the installer checks if your system meets the technical requirements to execute
Expand Down Expand Up @@ -178,3 +183,4 @@ the Symfony directory structure.
.. _`Composer download page`: https://getcomposer.org/download/
.. _`public checksums repository`: https://github.com/sensiolabs/checksums
.. _`these steps`: http://fabien.potencier.org/signing-project-releases.html
.. _`Phar extension`: http://php.net/manual/en/intro.phar.php
6 changes: 4 additions & 2 deletions book/controller.rst
Expand Up @@ -116,8 +116,10 @@ Controllers are also called *actions*.

This controller is pretty straightforward:

* *line 4*: Symfony takes advantage of PHP's namespace functionality to
namespace the entire controller class. The ``use`` keyword imports the
* *line 2*: Symfony takes advantage of PHP's namespace functionality to
namespace the entire controller class.

* *line 4*: Symfony again takes advantage of PHP's namespace functionality: the ``use`` keyword imports the
``Response`` class, which the controller must return.

* *line 6*: The class name is the concatenation of a name for the controller
Expand Down
2 changes: 1 addition & 1 deletion book/from_flat_php_to_symfony2.rst
Expand Up @@ -554,7 +554,7 @@ them for you. Here's the same sample application, now built in Symfony::
{
$posts = $this->get('doctrine')
->getManager()
->createQuery('SELECT p FROM AcmeBlogBundle:Post p')
->createQuery('SELECT p FROM AppBundle:Post p')
->execute();

return $this->render('Blog/list.html.php', array('posts' => $posts));
Expand Down
14 changes: 7 additions & 7 deletions book/includes/_service_container_my_mailer.rst.inc
Expand Up @@ -4,8 +4,8 @@

# app/config/services.yml
services:
my_mailer:
class: Acme\HelloBundle\Mailer
app.mailer:
class: AppBundle\Mailer
arguments: [sendmail]

.. code-block:: xml
Expand All @@ -15,10 +15,10 @@
<container xmlns="http://symfony.com/schema/dic/services"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://symfony.com/schema/dic/services
http://symfony.com/schema/dic/services/services-1.0.xsd"
>
http://symfony.com/schema/dic/services/services-1.0.xsd">

<services>
<service id="my_mailer" class="Acme\HelloBundle\Mailer">
<service id="app.mailer" class="AppBundle\Mailer">
<argument>sendmail</argument>
</service>
</services>
Expand All @@ -29,7 +29,7 @@
// app/config/services.php
use Symfony\Component\DependencyInjection\Definition;

$container->setDefinition('my_mailer', new Definition(
'Acme\HelloBundle\Mailer',
$container->setDefinition('app.mailer', new Definition(
'AppBundle\Mailer',
array('sendmail')
));
6 changes: 6 additions & 0 deletions book/installation.rst
Expand Up @@ -83,6 +83,11 @@ to meet those requirements.
distributing them. If you want to verify the integrity of any Symfony
version, follow the steps `explained in this post`_.

.. note::

If the installer doesn't work for you or doesn't output anything, make sure
that the `Phar extension`_ is installed and enabled on your computer.

Basing your Project on a Specific Symfony Version
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Expand Down Expand Up @@ -419,3 +424,4 @@ a wide variety of articles about solving specific problems with Symfony.
.. _`Symfony REST Edition`: https://github.com/gimler/symfony-rest-edition
.. _`FOSRestBundle`: https://github.com/FriendsOfSymfony/FOSRestBundle
.. _`Git`: http://git-scm.com/
.. _`Phar extension`: http://php.net/manual/en/intro.phar.php
4 changes: 2 additions & 2 deletions book/page_creation.rst
Expand Up @@ -191,7 +191,7 @@ at the end:
.. code-block:: xml
<!-- src/Acme/DemoBundle/Resources/config/routing.xml -->
<!-- app/config/routing.xml -->
<?xml version="1.0" encoding="UTF-8" ?>
<routes xmlns="http://symfony.com/schema/routing"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
Expand All @@ -205,7 +205,7 @@ at the end:
.. code-block:: php
// src/Acme/DemoBundle/Resources/config/routing.php
// app/config/routing.php
use Symfony\Component\Routing\RouteCollection;
use Symfony\Component\Routing\Route;
Expand Down
6 changes: 3 additions & 3 deletions book/routing.rst
Expand Up @@ -1186,9 +1186,9 @@ Notice that Symfony adds the string ``Controller`` to the class name (``Blog``
=> ``BlogController``) and ``Action`` to the method name (``show`` => ``showAction``).

You could also refer to this controller using its fully-qualified class name
and method: ``AppBundle\Controller\BlogController::showAction``.
But if you follow some simple conventions, the logical name is more concise
and allows more flexibility.
and method: ``AppBundle\Controller\BlogController::showAction``. But if you
follow some simple conventions, the logical name is more concise and allows
more flexibility.

.. note::

Expand Down

0 comments on commit b2b1239

Please sign in to comment.