I have prepared a newsletter with some edit textareas and some default text in it. User of my newsletter is able to edit text in text area, after which am saving the edited text when he clicks on preview button, In this page am showing all the text edited using PHP ($_POST[]). when SendNewsLetter button is clicked mail is sent but without any text in it, as am using PHP to display text. Is there any alternate way to display dynamic content in mail body. Thank in advance, Please help me out of this.
Below is the php code which is not working in email body. In preview it displays fine.
<table cellspacing="0" cellpadding="0" border="1" width="300px" height="auto" >
<tr><td><?php echo set_value('input1',$_POST['input1']); ?></td></tr>
</table>
This is my sendemail()
public function newsemail(){
$this->load->library('email');
$config['mailtype'] = 'html';
$header = $this->load->view('index/news1','',true);
$this->email->initialize($config);
$this->email->from('info@xyz.net', 'xyz Consulting');
$this->email->reply_to('info@xyz.net','xyz Consulting');
$this->email->to('mahboob@gmail.com');
//$this->email->cc('mehboob029@gmail.com');
$this->email->bcc('xyz@gmail.com');
$this->email->subject('Newsletter');
$this->email->message( $header );
$mail = $this->email->send();