Skip to content

Commit

Permalink
Fix typos
Browse files Browse the repository at this point in the history
  • Loading branch information
ifdattic committed Apr 7, 2014
1 parent ddcec07 commit 502d104
Show file tree
Hide file tree
Showing 5 changed files with 10 additions and 11 deletions.
4 changes: 2 additions & 2 deletions doc/cookbook/sub_requests.rst
Expand Up @@ -32,8 +32,8 @@ By calling ``handle``, you can make a sub-request manually. Here's an example::
$response = $app->handle($subRequest, HttpKernelInterface::SUB_REQUEST, false);

There's some more things that you need to keep in mind though. In most cases
you will want to forward some parts of the current master request to the sub-
request. That includes: Cookies, server information, session.
you will want to forward some parts of the current master request to the
sub-request. That includes: Cookies, server information, session.

Here is a more advanced example that forwards said information (``$request``
holds the master request)::
Expand Down
3 changes: 1 addition & 2 deletions doc/providers/form.rst
Expand Up @@ -127,8 +127,7 @@ example::
return $app['twig']->render('index.twig', array('form' => $form->createView()));
});

And here is the ``index.twig`` form template (requires ``symfony/twig-
bridge``):
And here is the ``index.twig`` form template (requires ``symfony/twig-bridge``):

.. code-block:: jinja
Expand Down
2 changes: 1 addition & 1 deletion doc/providers/monolog.rst
Expand Up @@ -13,7 +13,7 @@ Parameters

* **monolog.logfile**: File where logs are written to.

* **monolog.level** (optional): Level of logging defaults
* **monolog.level** (optional): Level of logging, defaults
to ``DEBUG``. Must be one of ``Logger::DEBUG``, ``Logger::INFO``,
``Logger::WARNING``, ``Logger::ERROR``. ``DEBUG`` will log
everything, ``INFO`` will log everything except ``DEBUG``,
Expand Down
10 changes: 5 additions & 5 deletions doc/providers/serializer.rst
Expand Up @@ -41,22 +41,22 @@ The ``SerializerServiceProvider`` provider provides a ``serializer`` service:
use Silex\Application;
use Silex\Provider\SerializerServiceProvider;
use Symfony\Component\HttpFoundation\Response;
$app = new Application();
$app->register(new SerializerServiceProvider());
// only accept content types supported by the serializer via the assert method.
$app->get("/pages/{id}.{_format}", function ($id) use ($app) {
// assume a page_repository service exists that returns Page objects. The
// object returned has getters and setters exposing the state.
$page = $app['page_repository']->find($id);
$format = $app['request']->getRequestFormat();
if (!$page instanceof Page) {
$app->abort("No page found for id: $id");
}
return new Response($app['serializer']->serialize($page, $format), 200, array(
"Content-Type" => $app['request']->getMimeType($format)
));
Expand Down
2 changes: 1 addition & 1 deletion doc/usage.rst
Expand Up @@ -462,7 +462,7 @@ the defaults for new controllers.
.. note::

The global configuration does not apply to controller providers you might
mount as they have their own global configuration (read the
mount as they have their own global configuration (read the
:doc:`dedicated chapter<organizing_controllers>` for more information).

Error handlers
Expand Down

0 comments on commit 502d104

Please sign in to comment.