Chapter 8: Last-Minute Upgrades
258
Here ’ s the markup for the admin_subs_mail view:
< ?php
echo form_open(‘admin/subscribers/sendemail’);
echo “ < p > < label for=’subject’ > Subject < /label > < br/ > ”;
$data = array(‘name’ = > ‘subject’, ‘id’ = > ‘subject’, ‘size’ = > 50);
echo form_input($data);
echo “ < /p > ”;
echo “ < p > < label for=’message’ > Message < /label > < br/ > ”;
$data = array(‘name’ = > ‘message’, ‘id’ = > ‘message’, ‘rows’ = > 20, ‘cols’ = > 50);
echo form_textarea($data);
echo “ < /p > ”;
echo “ < p > ”.form_checkbox(‘test’, ‘true’, TRUE). “ < b > This is a test! < /b > < /p > ”;
echo form_submit(‘submit’,’send email’);
echo form_close();
? >
Your form should look somewhat like Figure 8 - 8 at this point.
Figure 8 - 8