PHP - MVC question: So this is a pretty high level question about building an MVC. I have a class called page, and it needs to pull in classes for the model, view, and controller. There is also a Route class that has mostly attributes regarding the Path: /Class/Method/arg1/arg2 , etc
Right now the Page pulls in that Route object as its constructor param.
Should Model, View and Controller extend Page ? Whihle M,V,&C need certain information from the Route object, I don't think that logically a Model for instance extends a Page - because while it's a part of a page, it's not a different kind of page, and I'm not sure the M,V, & C need to be that intimate with each other.
But I thought I'd ask anyway. What I'm finding myself doing is the Page will pass that Route object to the controller when it instantiates it, then the same with the Model, View, etc.
I know every time you find yourself doing redundant things like this, it might be time to step back and rethink before you do too much work down that path.
But again, in my mind, the M,V, & C are not forms of a page, its more a composition thing.
Thoughts?
Thanks!