-- jasonzfw <[email protected]> wrote
(on Wednesday, 02 September 2009, 09:29 AM -0700):
> A few minutes after I sent the previous reply, that matter of ZF attempting
> to look up Default_Model_Category really stuck in my head, so I added the
> following line to my Category model:
> 
> protected $_name = 'category';
> 
> Sure enough, this fixed the problem. I tested identical code on my DreamHost
> server (which runs Linux), and the problem also exists there.
> 
> Is this addition the proper way to create models now? I can't imagine it
> would be, but maybe I missed something in one of the recent releases.

When your class name doesn't match the table name, you're required to
add it to your class just as you did above. I actually do this in all my
classes extending Zend_Db_Table for clarity.

-- 
Matthew Weier O'Phinney
Project Lead            | [email protected]
Zend Framework          | http://framework.zend.com/

Reply via email to