Failed to send AUTH LOGIN command. Error: 504 5.7.4 Unrecognized authentication type when send email with php

PHPMailer configuration code.

$config = Array(
        'useragent' => 'PHPMailer',
        'protocol' => 'smtp',
        'smtp_host' => 'webmail.waskitaprecast.co.id',
        'smtp_port' => 25
        'smtp_user' => '****@waskitaprecast.co.id',
        'smtp_pass' => '*****',
        'charset'   => 'iso-8859-1',
        'wordwrap' => TRUE,
        'smtp_timeout' => '30',
        'mailpath' => '/usr/sbin/sendmail',
        'mailtype' => 'html'
    );

and i got this error

220 WBP-EXCH-01.wbp.local Microsoft ESMTP MAIL Service ready at Thu, 12 Jul 2018 14:15:18 +0700 hello: 250-WBP-EXCH-01.wbp.local Hello [10.10.2.74]

250-SIZE 26214400

250-PIPELINING

250-DSN

250-ENHANCEDSTATUSCODES 250-8BITMIME

250-BINARYMIME

250 CHUNKING

Failed to send AUTH LOGIN command. Error: 504 5.7.4 Unrecognized authentication type Unable to send email using PHP SMTP. Your server might not be configured to send mail using this method.

please help me :(

1 answer

  • answered 2018-07-12 07:45 MrSmile

    Try to change:

    'protocol' => 'smtp',
    

    to

    'protocol' => 'sendmail',