Skip to content

Commit f8fb828

Browse files
committed
[#2196] Moving where the SQLite details are just because this section has so many notes and sidebars already
1 parent 63e2d7e commit f8fb828

File tree

1 file changed

+38
-37
lines changed

1 file changed

+38
-37
lines changed

book/doctrine.rst

+38-37
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ for you:
8686
8787
$ php app/console doctrine:database:create
8888
89-
.. sidebar:: Setting Up The Database
89+
.. sidebar:: Setting Up The Database to be UTF8
9090

9191
One mistake even seasoned developers make when starting a Symfony2 project
9292
is forgetting to setup default charset and collation on their database,
@@ -112,43 +112,44 @@ for you:
112112
collation-server = utf8_general_ci
113113
character-set-server = utf8
114114
115-
.. note::
116-
117-
If you want to use SQLite as your database, you need to set the path
118-
where your database file should be stored:
115+
Using SQLite
116+
~~~~~~~~~~~~
119117

120-
.. configuration-block::
121-
122-
.. code-block:: yaml
123-
124-
# app/config/config.yml
125-
doctrine:
126-
dbal:
127-
driver: pdo_sqlite
128-
path: "%kernel.root_dir%/sqlite.db"
129-
charset: UTF8
130-
131-
.. code-block:: xml
132-
133-
<!-- app/config/config.xml -->
134-
<doctrine:config
135-
driver="pdo_sqlite"
136-
path="%kernel.root_dir%/sqlite.db"
137-
charset="UTF-8"
138-
>
139-
<!-- ... -->
140-
</doctrine:config>
141-
142-
.. code-block:: php
143-
144-
// app/config/config.php
145-
$container->loadFromExtension('doctrine', array(
146-
'dbal' => array(
147-
'driver' => 'pdo_sqlite',
148-
'path' => '%kernel.root_dir%/sqlite.db',
149-
'charset' => 'UTF-8',
150-
),
151-
));
118+
If you want to use SQLite as your database, you need to set the path
119+
where your database file should be stored:
120+
121+
.. configuration-block::
122+
123+
.. code-block:: yaml
124+
125+
# app/config/config.yml
126+
doctrine:
127+
dbal:
128+
driver: pdo_sqlite
129+
path: "%kernel.root_dir%/sqlite.db"
130+
charset: UTF8
131+
132+
.. code-block:: xml
133+
134+
<!-- app/config/config.xml -->
135+
<doctrine:config
136+
driver="pdo_sqlite"
137+
path="%kernel.root_dir%/sqlite.db"
138+
charset="UTF-8"
139+
>
140+
<!-- ... -->
141+
</doctrine:config>
142+
143+
.. code-block:: php
144+
145+
// app/config/config.php
146+
$container->loadFromExtension('doctrine', array(
147+
'dbal' => array(
148+
'driver' => 'pdo_sqlite',
149+
'path' => '%kernel.root_dir%/sqlite.db',
150+
'charset' => 'UTF-8',
151+
),
152+
));
152153
153154
Creating an Entity Class
154155
~~~~~~~~~~~~~~~~~~~~~~~~

0 commit comments

Comments
 (0)