I have created a Zend Framework model by extending Zend_Db_Table_Absract
as follows (simplified example):
class Foos extends Zend_Db_Table_Abstract
{
protected $_schema = 'Foo';
protected $_name = 'Foos';
protected $_primary = 'id';
protected $_sequence = true;
public function insert($data) {
$db = $this->getAdapter();
$record = array('field1' => $data['field1'],
'field2' => $data['field2'],
...
);
return parent::insert($record);
}
}
The above correctly inserts a record. The problem is, I keep getting the following notice:
Strict Standards: Declaration of Foos::insert() should be compatible with that of Zend_Db_Table_Abstract::insert() in /x/x/x/Foo.php on line XX
As far as I can tell from having read the documentation and API several times, the way I am doing it is correct. I am aware that I can turn off E_STRICT
but I would much rather know why I am getting the above notice. Any ideas? (PHP 5.3, Zend Framework 1.10)