[eluser]Ben Edmunds[/eluser]
Hey Carlos,
Theoretically you could build an entire site with one controller but the code would quickly become unmanageable and just bad.
First off some semantics, the controller files are usually called controllers and the controller's functions are usually called methods or actions.
So what you want to do is separate you site logically into controllers. For example, if you have a site with a home page, blog, and article page you would probably want three controllers; welcome, blog, articles and then you would have methods inside those preforming the actions for that part of the site.
As an example your blog controller might look like this:
blog.php
Code:
class Blog extends Controller {
function index() {
//display the blog posts
}
function view($id) {
//display the blog post by id
}
function post() {
//new blog post
}
}
Make sense?