I have a model called Queuedemail that is responsible for storing in a
database emails that are going to be sent at a later time using a
cronjob.
One of the columns of this table is called email_body.
Before saving the data to the database I would like to load a view to
a variable and save this into the "email_body" column. This is what I
would do if this was inside a controller:
$emailBody = $this->render('/elements/email/html/body', 'email/html/
default');
I know this won't work inside the model, so how could I call a
controller from the model so I could ask it to load this view?
Thanks a lot,
Burningfuses
--
Our newest site for the community: CakePHP Video Tutorials
http://tv.cakephp.org
Check out the new CakePHP Questions site http://ask.cakephp.org and help others
with their CakePHP related questions.
To unsubscribe from this group, send email to
[email protected] For more options, visit this group at
http://groups.google.com/group/cake-php