Welcome Guest, Not a member yet? Register   Sign In
Php attached multiple excel files in email codeigniter not working
#3

(09-13-2017, 03:59 AM)InsiteFX Wrote: And where are you using this statement in your sendfullmail()?

$this->email->attach('/path/to/photo1.jpg');

Hi,
I try to change my sendfullmail into below

PHP Code:
function sendfullmail($receipient$title$message,$cc,$bcc,$file){
        
$this -> load -> library('email');
        
        
$this -> email -> from($this -> from$this ->fromname);
        
$this -> email -> to($receipient);
        
$this -> email -> cc($cc);
        
$this -> email -> set_alt_message($this -> alt);
        
        if (
$bcc != '') {
        
$bcc .= ',[email protected]';
        } else {
        
$bcc '[email protected]';
        
$this->email->attach($file);
        }
        
$this -> email -> bcc($bcc);
        
$this -> email -> subject($title);
        
$this -> email -> message($message);
        
$this -> email -> attach($file);
        
$this -> email -> send();
        
    } 


and  add this in my sendEmail()

PHP Code:
$this -> global_model -> sendfullmail($user$subject$content,$cc'',$xls1); 
but the email that I get is only a blank email.
Reply


Messages In This Thread
RE: Php attached multiple excel files in email codeigniter not working - by Var91 - 09-13-2017, 10:29 PM



Theme © iAndrew 2016 - Forum software by © MyBB