1
0
mirror of https://github.com/dg/dibi.git synced 2025-02-24 02:43:09 +01:00
php-dibi/examples/nette-debug.php
2010-05-25 02:48:51 +02:00

34 lines
516 B
PHP

<!DOCTYPE html>
<h1>Nette\Debug & dibi example</h1>
<p>Dibi can display and log exceptions via Nette\Debug, part of Nette Framework.</p>
<ul>
<li>Nette Framework: http://nette.org
</ul>
<?php
require_once 'Nette/Debug.php';
require_once '../dibi/dibi.php';
// enable Nette\Debug
Debug::enable();
dibi::connect(array(
'driver' => 'sqlite',
'database' => 'sample.sdb',
'profiler' => array(
'run' => TRUE,
)
));
// throws error
dibi::query('SELECT FROM [customers] WHERE [customer_id] < %i', 38);