True, in the Zend Framework you need to declare classes for the database tables that you want to access. But everything else can be done implicitly, if the default is enough. The following is a valid and functional class for the model (compare with http://framework.zend.com/manual/en/zend.db.table.html#zend.db.table.introduction ):
class bugs extends Zend_Db_Table_Abstract {
This will allow you to access a table named "errors", for example:
$table = new bugs(); $data = array( 'created_on' => '2007-03-22', 'bug_description' => 'Something wrong', 'bug_status' => 'NEW' ); $table->insert($data);
Again, the example was taken directly from the documentation mentioned above.
source share