Home » Database » DB_DataObject » Bug #820
not reading configuration in insert() function
Details
| Submitted | 2004-02-21 15:33 UTC |
|---|---|
| From | dragun at yegon dot sk |
| Assigned | alan_k |
| Status | Closed |
| Package | DB_DataObject |
| PHP Version | 4.3.2 |
| OS | Debian Linux |
| Roadmaps | (Not assigned) |
Comments
[2004-02-21 15:33 UTC] dragun at yegon dot sk
Description:
------------
when trying to insert data into a table the configuration is not loaded, that means that some directives like quote_entities in the do.ini file are ignored
the code
function insert()
{
global $_DB_DATAOBJECT;
$quoteEntities = @$_DB_DATAOBJECT['CONFIG']['quote_entities'];
should read in my opinion like this
function insert()
{
global $_DB_DATAOBJECT;
if (empty($_DB_DATAOBJECT['CONFIG'])) {
DB_DataObject::_loadConfig();
}
$quoteEntities = @$_DB_DATAOBJECT['CONFIG']['quote_entities'];
otherwise the quote_entities directive is totaly ignored