|
I am trying to compare traditional website structure to Zend FW MVC structure and I would like your thoughts / suggestions on something.
If a traditional website has an index.php, about.php, contact.php etc and they are all sitting in the site's document root. How would you guys move this to MVC? 1) Have indexController include indexAction, aboutAction, contactAction, etc and only use a new xxxxController to take the place of a directory in the document root Or 2) Make a class for each of the traditional pages: aboutController, contactController, etc. I would like to be able to picture the ZF MVC structure of a traditional site. Thanks a lot! Jason DEBORD Limoges, France |
|
Thanks for the reply.
You're right, it is overkill, but I'm basically doing this as to get some experience with MVC. I'm not a fan of Smarty, but I understand why you suggested it. My goal is to write a simple application that mimics a traditional website. And build on it from there. So what would you do? One index controller with numerous actions? Or numerous controllers each with an index action? I'd also like to do something with Zend_Translate. Any advice is greatly appreciated. Thanks again! Jason DEBORD Limoges, France On Thu, Feb 12, 2009 at 1:25 PM, Steven Wright <[hidden email]> wrote:
|
|
Hi,
If it was me I would create an action per page. If
then you decided to implement CRUD per page this would be easily achieved by
adding the relevant action to the controller.
Like I said, this is how I would do it
:-)
I do this in my code see: http://code.google.com/p/jotbug/source/browse/#svn/trunk/JotBug/application/controllers
- Robert From: Jason DeBord [mailto:[hidden email]] Sent: 12 February 2009 12:47 To: Steven Wright; [hidden email] Subject: Re: [fw-general] Thoughts on general website setup You're right, it is overkill, but I'm basically doing this as to get some experience with MVC. I'm not a fan of Smarty, but I understand why you suggested it. My goal is to write a simple application that mimics a traditional website. And build on it from there. So what would you do? One index controller with numerous actions? Or numerous controllers each with an index action? I'd also like to do something with Zend_Translate. Any advice is greatly appreciated. Thanks again! Jason DEBORD Limoges, France On Thu, Feb 12, 2009 at 1:25 PM, Steven Wright <[hidden email]>
wrote:
________________________________________________________________________ This email has been scanned for all known viruses by the MessageLabs Email Security Service and the Macro 4 plc internal virus protection system. ________________________________________________________________________ ________________________________________________________________________ This email has been scanned for all known viruses by the MessageLabs Email Security Service and the Macro 4 plc internal virus protection system. ________________________________________________________________________ |
| Powered by Nabble | Edit this page |
