Simon R Jones schreef:
In ZF most of the business logic ends up in the controller file, so an
AdminController.php, in my experience so far, becomes quickly unweildy if
there is only one controller file to manage admin tasks (i.e. reporting,
adding/editing items).
For me it's common practice to have a controller per "subject". For
instance, a NewsController, BlogController, FooController, etc, etc...
A controller processes and responds to events (typically user actions),
and these "processes" vary for each subject/module pair, you usually end
up having the same controller in each module, but with different
business logic.
website/NewsController.php
admin/NewsController.php
super-admin/NewsController.php
super-duper-admin/NewsController.php
Where "website", "admin", "super-admin", "super-duper-admin", are the so
called "modules", which are actually just folders....
I hope this makes a little sense?
Best regards,
--
Andries Seutens
http://andries.systray.be
i18n Locale Team is looking for your help. Volunteers are always welcome to
contribute their feedback, bug fixes, suggestions for enhancements and
improvements, experimental patches, and especially their ideas on the fw-i18n
mail list.
Are you enjoying the wiki manual? They are frequently updated and incubator
documentation is also included!
Live manual: http://framework.zend.com/wiki/display/ZFDOCDEV
Incubator manual: http://framework.zend.com/wiki/display/ZFDOC
Gecontroleerd op virussen door de JOJO Secure Gateway.