0

I have been following this documentation here:

https://www.mailjet.com/docs/code/php/codeigniter

In my config folder I created a php file as shown above like this:

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

$config['protocol'] = 'smtp';
$config['smtp_host'] = 'ssl://in.mailjet.com';
$config['smtp_port'] = '465';
$config['smtp_user'] = 'API key';
$config['smtp_pass'] = 'Pass Key';
$config['charset'] = 'utf-8';
$config['mailtype'] = 'html';
$config['newline'] = "\r\n";

?>

But I am still getting the following error:

An Error Was Encountered
Non-existent class: Email

When I try to load the lib like this in a controller:

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

$this->email->from('your_sender@address.com', 'You');
$this->email->to('recipient@example.com');
$this->email->subject('My first email by Mailjet');
$this->email->message('Hello from Mailjet & CodeIgniter !');

$this->email->send();

Cheers.

thejoker
  • 159
  • 1
  • 5
  • 17

1 Answers1

0

You haven't got any file Email in System directory