0

I am using codeinter email for sending mail. Mail's sent successfully but it is not received.

Here is my code:

function send_verify_email($email)
{
    $email_code = md5($email);

    $config = Array(
        'protocol' => 'smtp',
        'smtp_crypto'=> 'ssl',
        'smtp_host' => 'ssl://smtp.googlemail.com',
        'smtp_port' => 587,
        'smtp_user' => 'test@gmil.com', // change it to yours
        'smtp_pass' => '***', // change it to yours
        'mailtype' => 'html',
        'charset' => 'iso-8859-1',
        'wordwrap' => TRUE
    );

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

    $this->email->set_newline("\r\n");
    // $this->email->set_mailtype("html");
    $this->email->from('test@gmail.com', "TalentRiser Update Password");
    $this->email->to('receiver@gmail.com');
    $this->email->subject("Update Password");                  
    $this->email->message('hello for test');
    if($this->email->send())
    {
        echo "success";
    }
    else
    {
        echo "Failed";
    }
}
FirstOne
  • 6,033
  • 7
  • 26
  • 45
subrat
  • 11
  • 3
  • Is there an error message? – ventiseis Dec 20 '17 at 19:04
  • no, it is showing success message but i am not receiving the mail, can you please help me to solve this.. – subrat Dec 20 '17 at 19:06
  • is there anyone who can help me, with given question? – subrat Dec 23 '17 at 10:48
  • Did you read the linked question and the answers? Did you check every point? Server logs, mails logs, etc.? – ventiseis Dec 23 '17 at 20:22
  • yes, when i talk with my hosting provider, they found one error, and the error is " We could see that your domain is calling 'Email.php' file since the file does not exist in your document root folder". Now i am not getting any solution for solve this error. – subrat Dec 25 '17 at 10:30
  • who put this question as a duplicate, where he is give me the ans – subrat Dec 29 '17 at 11:07
  • So, you have an error message and somehow a misconfiguration in your `php` files. The only thing I can advise you is that you sit down, check each and every line of your files and configuration. You will find the error, but it takes some time. StackOverflow users don't have access to your server, so nobody can guess which files doesn't exist. Besides. this error message doesn't look as if its related to your email sending issue. – ventiseis Dec 29 '17 at 11:35

0 Answers0