Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

202
Vistas
Codeigniter Email cc and bcc not working

I am using Email library of codeigniter. This code is properly sending mail to $to variable.but not to $cc and $bcc. Please help me if anybody could!

$this->load->library('email');
$this->email->from($from);
$this->email->bcc($bcc);
$this->email->cc($cc);
$this->email->to($to);
$this->email->subject($subject);
$this->email->message($content);
$this->email->send();
over 4 years ago · Santiago Trujillo
2 Respuestas
Responde la pregunta

0

Youre wrong the code, use an array on BCC.

$this->email->bcc(array($this->input->post('bcc_email')));
over 4 years ago · Santiago Trujillo Denunciar

0

Use this library:

$this->load->library('email');

then use this code, its working at my side:

$this->email->from('your@example.com', $this->input->post('fullname'));
$this->email->to($this->input->post('email'));
$this->email->cc($this->input->post('cc_email'));
$this->email->bcc($this->input->post('bcc_email'));
$this->email->subject('Registeration Notification');
$this->email->message('You have registered successfully.\nYour username is :'.$this->input->post('email'));

$this->email->send();
over 4 years ago · Santiago Trujillo Denunciar
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda