Rahul
Rahul

Reputation: 922

Zend framework techniques

I am trying to migrate to zend framework. Should each webpage be a Controller or an action.

What is the advantage of having multiple actions. Can they talk to each other? and whats the best use of Action helpers and View helpers.

Please guide me on how to start on the framework.. thanks

Upvotes: 2

Views: 123

Answers (5)

wezzy
wezzy

Reputation: 5935

You can use a new controller for each page or define multiple actions on the same controller to render your pages. I choose to use defferent action from the same controller to display variuos pages. Using multiple action on the same controller allows you to put some code in che constructor of the controller that is executed for each action. For example i have a controller for all the pulic pages of a website and a new controller for those pages that are reserved to registered users. In the constructor for the controller dedicated to registered user i do the check for authentication.

Upvotes: 3

Rebol Tutorial
Rebol Tutorial

Reputation: 2754

First get a sound understand of MVC Framework: Understanding MVC Architecture from its Origin (part I) http://learnnewprogramming.com/blog/understanding-mvc-architecture/

Upvotes: 1

hsz
hsz

Reputation: 152206

Those links are from Zend Framework manual.
Do not afraid and click - read the Introduction chapters - you will have all answers. ;-)

Upvotes: 1

Sarfraz
Sarfraz

Reputation: 382626

You got to create a controller for each of your site's pages. If any page interacts with db, you should also create model for that page. Also you should create view for each of your page.

If you have no idea about MVC, you can read this:

MVC

Upvotes: 1

Roch
Roch

Reputation: 22041

You should check that page about MVC applications, It's not precisely related to Zend. But you seems to be asking what a MVC Design Pattern is.

Upvotes: 1

Related Questions