codeguy/Slim-Extras — pull request #72 by tuupola (2013-05-24 11:01:43+00:00)
Title: PHP ActiveRecord logging via Slim logger.

Adapter which enables logging from [PHP ActiveRecord](http://www.phpactiverecord.org/) to Slim Logger. Been using this myself for a while.

```php
$app = new \Slim\Slim(array(
'log.writer' => new \Slim\Extras\Log\DateTimeFileWriter()
));

ActiveRecord\Config::initialize(function($cfg) use ($connections, $app) {
$cfg->set_connections($connections);
$cfg->set_logging(true);
$cfg->set_logger(new \Slim\Extras\Log\ActiveRecordAdapter($app->getLog(), \Slim\Log::DEBUG));
});
```