I have a web site that built from the ground up, and im seriously considering transferring this site over to the Yii framework. Im kinda stuck on the “proper” why to do it. I have a few classes that where written for the site. One particular one is an e-mail function that is based on database templates. The class reacts to different actions in the system, pull the info from the DB and fill in e-mail templates that get sent out.
Do i move this email system into the Modules layer? Controller Layer or should it be re-written as an extension?
I have to admit that i am new to MVR and frameworks so any help advice would be appreciated.
Within Yii, you’re probably looking at a combination. The custom email sending function would probably be best as an extension that you can then call from other controllers with ease. Administering the templates would warrant a model and controller for your CRUD interaction with the templates.