Download the PHP package tburschka/zf2-doctrine-sql-logger without Composer
On this page you can find all versions of the php package tburschka/zf2-doctrine-sql-logger. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Please rate this library. Is it a good library?
Informations about the package zf2-doctrine-sql-logger
ZF2DoctrineSQLLogger
Logs Doctrine DBAL queries as plain SQL with a Zend\Log\Logger.
Usage
-
Add to require list in composer.json file (and of cause execute
composer.phar update
)"tburschka/zf2-doctrine-sql-logger": "~1.0"
-
Add to modules list in application.config.php
'ZF2DoctrineSQLLogger'
-
Create a new Zend\Log\Logger or use an existing one
[...] 'service_manager' => array( 'factories' => array( 'doctrine.sql_logger' => function () { $writer = new Zend\Log\Writer\Stream('data/logger_doctrine_sql.log'); $logger = new Zend\Log\Logger(); $logger->addWriter($writer); return $logger; }, ), ), [...]
-
Configure the Z2fDoctrineSQLLogger
[...] 'ZF2DoctrineSQLLogger' => array( 'entitymanager' => 'doctrine.entitymanager.orm_default', 'logger' => 'doctrine.sql_logger', 'priority' => Zend\Log\Logger::NOTICE, 'log_executiontime' => false, ), [...]
-
Enable logger for doctrine
[...] 'doctrine' => array( 'configuration' => array( 'orm_default' => array( 'sql_logger' => 'ZF2DoctrineSQLLogger', ), ), ), [...]
All versions of zf2-doctrine-sql-logger with dependencies
PHP Build Version
Package Version
Requires
php Version
>=5.3.23
doctrine/doctrine-orm-module Version *
zendframework/zend-servicemanager Version ~2.3
doctrine/doctrine-orm-module Version *
zendframework/zend-servicemanager Version ~2.3
The package tburschka/zf2-doctrine-sql-logger contains the following files
Loading the files please wait ....