/** * Adds ability to get records by an array of primary keys */ public function get($k = null, $v = null) { if (is_array($k)) { $k = $this->sqlin($k); $this->whereAdd('id IN(' . $k . ')'); return $this->find(); } else { if (is_null($v) || $this->__keystore == $k) { if (!($ret = DB_DataObject_Pluggable::retreiveFromRegistry($this->tableName(), $k, $v, $this))) { if ($ret = parent::get($k, $v)) { DB_DataObject_Pluggable::storeToRegistry($this); return $ret; } } return $ret; } return parent::get($k, $v); } }
public function get($k = null, $v = null) { // avoid those annoying PEAR::DB strict standards warnings it causes $old = error_reporting(); error_reporting(error_reporting() & ~E_STRICT); $res = parent::get($k, $v); // reset error_reporting($old); return $res; }