Email HEADERS with "Email" class

#11
[eluser]Samus[/eluser]
[quote author="skattabrain" date="1337778285"]Here, maybe of value for someone... very simple though...

Place in application/libraries/MY_Email.php

Code:
<?php  if ( ! defined('BASEPATH')) exit('No direct script access allowed');

class MY_Email extends CI_Email {

public function set_custom_header($header_name='', $header_value = '')
{
  if($header_name=='') {
   return FALSE;
  }

  $this->_set_header($header_name, $header_value);

  return $this;
}

}
[/quote]
Thanks. Just realized all my HTML emails were getting destroyed because they weren't quoted-printable encoded

#12
[eluser]behnampmdg3[/eluser]
Code:
$this->load->library('email');
    $this->email->from('[email protected]', 'Ben Igniter');
    $this->email->to($_POST['email']);
    $this->email->subject('CodeIgniter');
    $this->email->message('Sending a test email');
    $this->email->send();


Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  


  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2020 MyBB Group.