DB_DataObject::debugLevel
DB_DataObject::debugLevel – set the amount of debugging output
Synopsis
void DB_DataObject::debugLevel (
integer $level
)
Описание
Sets and returns debug level. So you can see the queries and connections being built and executed.
Parameter
-
integer $level
- level, without any parameters it will disable the debugging output. 1 give a general output, 5 includes things like passwords for connections.
Замечание
This function can not be called statically.
See
Пример
Using debugLevel()
<?php
// turn debugging high
DB_DataObject::debugLevel(5);
$person = new DataObjects_Person;
$person->get(12);
$person->setFrom($_POST['input']);
$person->update();
// turn debugging off
DB_DataObject::debugLevel();
?>