Skip to content

Commit

Permalink
fix include directive so that the contents are really included
Browse files Browse the repository at this point in the history
  • Loading branch information
xabbuh committed Jan 22, 2014
1 parent b9bbe5d commit 3090cf2
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 5 deletions.
5 changes: 2 additions & 3 deletions book/includes/_service_container_my_mailer.rst.inc
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,7 @@
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"
>

>
<services>
<service id="my_mailer" class="Acme\HelloBundle\Mailer">
<argument>sendmail</argument>
Expand All @@ -33,4 +32,4 @@
$container->setDefinition('my_mailer', new Definition(
'Acme\HelloBundle\Mailer',
array('sendmail')
));
));
4 changes: 2 additions & 2 deletions book/service_container.rst
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ for you. In order for this to work, you must *teach* the container how to
create the ``Mailer`` service. This is done via configuration, which can
be specified in YAML, XML or PHP:

.. include includes/_service_container_my_mailer.rst.inc
.. include:: includes/_service_container_my_mailer.rst.inc

.. note::

Expand Down Expand Up @@ -643,7 +643,7 @@ which has a ``getMailerMethod()`` method on it, which will return a string
like ``sendmail`` based on some configuration. Remember that the first argument
to the ``my_mailer`` service is the simple string ``sendmail``:

.. include includes/_service_container_my_mailer.rst.inc
.. include:: includes/_service_container_my_mailer.rst.inc

But instead of hardcoding this, how could we get this value from the ``getMailerMethod()``
of the new ``mailer_configuration`` service? One way is to use an expression:
Expand Down

0 comments on commit 3090cf2

Please sign in to comment.