[Catalyst] Getting Started
David Storrs
dstorrs at dstorrs.com
Fri Aug 5 22:20:19 CEST 2005
On Aug 5, 2005, at 4:06 PM, Christopher H. Laco wrote:
> First, is it a correct assumption to make that the interaction
> between Model and View is just a matter of the Controller stuffing
> things into the stash?
It is just a question of SOMETHING stuffing things in the stash.
What does the stuffing is open to question...there was a long thread
on this recently. It is summarized briefly here:
http://dev.catalyst.perl.org/wiki/NecessaryBackgroundKnowledge
along with a bunch of other information that should help you out.
> Lastly, [trying to get a mental handle on whatcodes goes where in a
> conversion], is it really just a matter of moving all of the non
> presentation logic of the TT based site (cookie reads/writes, form
> posts, redirects) into a Controller and leaving the presentation
> code in the templates?
Mostly. As with everything, it can be argued in multiple ways.
Here's how I do it:
- Presentation logic is mostly in the templates
- Views mostly just set which template to display
- Models are a thin wrapper over the database
- Controllers manage the business logic
--Dks
More information about the Catalyst
mailing list