We're in the process of rewriting our biggest app MVC-style.
The code is a complete mess but the one solid thing is the templating done with Smarty, so we want to stick with it.
I don't really have any Smarty experience and I'm not sure how to properly implement it in the MVC context; what's better?
- Instantiate the class every time its needed (ie the controllers)?
- Instantiate the class once during the bootstrap process and pass it as a parameter to the controllers?
(right now its a global variable, which afaik isn't ideal)
thanks!