5.4.2.1 Setting up the Layouts
To use both text and html mailing message you need to create layout files for them, just like in setting up your default layouts for the display of your views in a browser, you need to set up default layouts for your email messages. In the app/views/layouts/ directory you need to set up (at a minimum) the following structure
email/ html/ default.ctp text/ default.ctp
email/html/default.ctptext/default.ctp
These are the files that hold the layout templates for your default messages. Some example content is below
email/text/default.ctp
<?php echo $content_for_layout; ?>
<?php echo $content_for_layout; ?>
email/html/default.ctp
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> <html> <body> <?php echo $content_for_layout; ?> </body> </html>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"><html><body><?php echo $content_for_layout; ?></body></html>


























