Fix some glitches in the docs:
This commit is contained in:
parent
b794643735
commit
6309710ccc
@ -134,7 +134,8 @@ the ``ClassLoader`` with the following code.
|
|||||||
|
|
||||||
<?php
|
<?php
|
||||||
require 'Doctrine/Common/ClassLoader.php';
|
require 'Doctrine/Common/ClassLoader.php';
|
||||||
$classLoader = new \Doctrine\Common\ClassLoader();
|
$classLoader = new \Doctrine\Common\ClassLoader('Doctrine');
|
||||||
|
$classLoader->register();
|
||||||
|
|
||||||
The packages are installed in to your shared PEAR PHP code folder
|
The packages are installed in to your shared PEAR PHP code folder
|
||||||
in a folder named ``Doctrine``. You also get a nice command line
|
in a folder named ``Doctrine``. You also get a nice command line
|
||||||
|
@ -53,7 +53,7 @@ dealing exclusively with DBAL, the ConnectionHelper is required:
|
|||||||
.. code-block:: php
|
.. code-block:: php
|
||||||
|
|
||||||
<?php
|
<?php
|
||||||
$helperSet = new \Symfony\Components\Console\Helper\HelperSet(array(
|
$helperSet = new \Symfony\Component\Console\Helper\HelperSet(array(
|
||||||
'db' => new \Doctrine\DBAL\Tools\Console\Helper\ConnectionHelper($conn)
|
'db' => new \Doctrine\DBAL\Tools\Console\Helper\ConnectionHelper($conn)
|
||||||
));
|
));
|
||||||
$cli->setHelperSet($helperSet);
|
$cli->setHelperSet($helperSet);
|
||||||
@ -64,7 +64,7 @@ required:
|
|||||||
.. code-block:: php
|
.. code-block:: php
|
||||||
|
|
||||||
<?php
|
<?php
|
||||||
$helperSet = new \Symfony\Components\Console\Helper\HelperSet(array(
|
$helperSet = new \Symfony\Component\Console\Helper\HelperSet(array(
|
||||||
'em' => new \Doctrine\ORM\Tools\Console\Helper\EntityManagerHelper($em)
|
'em' => new \Doctrine\ORM\Tools\Console\Helper\EntityManagerHelper($em)
|
||||||
));
|
));
|
||||||
$cli->setHelperSet($helperSet);
|
$cli->setHelperSet($helperSet);
|
||||||
@ -97,7 +97,7 @@ typical ``cli-config.php`` file looks as follows:
|
|||||||
|
|
||||||
$em = \Doctrine\ORM\EntityManager::create($connectionOptions, $config);
|
$em = \Doctrine\ORM\EntityManager::create($connectionOptions, $config);
|
||||||
|
|
||||||
$helperSet = new \Symfony\Components\Console\Helper\HelperSet(array(
|
$helperSet = new \Symfony\Component\Console\Helper\HelperSet(array(
|
||||||
'db' => new \Doctrine\DBAL\Tools\Console\Helper\ConnectionHelper($em->getConnection()),
|
'db' => new \Doctrine\DBAL\Tools\Console\Helper\ConnectionHelper($em->getConnection()),
|
||||||
'em' => new \Doctrine\ORM\Tools\Console\Helper\EntityManagerHelper($em)
|
'em' => new \Doctrine\ORM\Tools\Console\Helper\EntityManagerHelper($em)
|
||||||
));
|
));
|
||||||
|
Loading…
x
Reference in New Issue
Block a user