Commit 54aa24f1 authored by Adrien BRAULT's avatar Adrien BRAULT

[Doc] Fix code-blocks, links, identation

parent aee53c94
......@@ -7,9 +7,13 @@ medium to large websites use a database to store sessions instead of files,
because databases are easier to use and scale in a multi-webserver
environment.
Symfony2's ``NativeSessionStorage`` has multiple storage handlers and one of
them uses PDO to store sessions, ``PdoSessionHandler``. To use it, replace the
``session.storage.handler`` service in your application like explained below.
Symfony2's `NativeSessionStorage
<http://api.symfony.com/master/Symfony/Component/HttpFoundation/Session/Storage/NativeSessionStorage.html>`_
has multiple storage handlers and one of them uses PDO to store sessions,
`PdoSessionHandler
<http://api.symfony.com/master/Symfony/Component/HttpFoundation/Session/Storage/Handler/PdoSessionHandler.html>`_.
To use it, replace the ``session.storage.handler`` service in your application
like explained below.
Example
-------
......
......@@ -52,9 +52,9 @@ Registering
.. code-block:: php
$app->register(new Silex\Provider\DoctrineServiceProvider(), array(
'db.options' => array(
'driver' => 'pdo_sqlite',
'path' => __DIR__.'/app.db',
'db.options' => array(
'driver' => 'pdo_sqlite',
'path' => __DIR__.'/app.db',
),
));
......
......@@ -59,7 +59,7 @@ Usage
The MonologServiceProvider provides a ``monolog`` service. You can use it to
add log entries for any logging level through ``addDebug()``, ``addInfo()``,
``addWarning()`` and ``addError()``:
``addWarning()`` and ``addError()``::
use Symfony\Component\HttpFoundation\Response;
......
......@@ -14,7 +14,9 @@ Parameters
* **session.storage.options**: An array of options that is passed to the
constructor of the ``session.storage`` service.
In case of the default ``NativeSessionStorage``, the possible options are:
In case of the default `NativeSessionStorage
<http://api.symfony.com/master/Symfony/Component/HttpFoundation/Session/Storage/NativeSessionStorage.html>`_,
the possible options are:
* **name**: The cookie name (_SESS by default)
* **id**: The session id (null by default)
......@@ -40,8 +42,9 @@ Services
data.
* **session.storage.handler**: A service that is used by the
``session.storage`` for data access. Defaults to a
``FileSessionHandler`` storage handler.
``session.storage`` for data access. Defaults to a `FileSessionHandler
<http://api.symfony.com/master/Symfony/Component/HttpFoundation/Session/Storage/Handler/FileSessionHandler.html>`_
storage handler.
Registering
-----------
......
......@@ -74,7 +74,7 @@ Registering
Usage
-----
The Swiftmailer provider provides a ``mailer`` service:
The Swiftmailer provider provides a ``mailer`` service::
$app->post('/feedback', function () use ($app) {
$request = $app['request'];
......
......@@ -216,7 +216,8 @@ don't want to mess with most of them.
`unset($app['exception_handler'])`.
* **logger**: A
`http://api.symfony.com/master/Symfony/Component/HttpKernel/Log/LoggerInterface.html`_
`LoggerInterface
<http://api.symfony.com/master/Symfony/Component/HttpKernel/Log/LoggerInterface.html>`_
instance. By default, logging is disabled as the value is set to `null`.
When the Symfony2 Monolog bridge is installed, Monolog is automatically used
as the default logger.
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment