/home/techb158/exp.abdallabala.com/vendor/phpmailer/phpmailer/examples
NameSizeModeActions
images/-0755rm
scripts/-0755rm
styles/-0755rm
code_generator.phps279160644editdlrm
contactform.phps24610644editdlrm
contents.html6450644editdlrm
contentsutf8.html9080644editdlrm
DKIM.phps13360644editdlrm
exceptions.phps14820644editdlrm
gmail.phps33060644editdlrm
gmail_xoauth.phps26770644editdlrm
index.html62890644editdlrm
mail.phps10630644editdlrm
mailing_list.phps22970644editdlrm
pop_before_smtp.phps21960644editdlrm
sendmail.phps11350644editdlrm
send_file_upload.phps16830644editdlrm
send_multiple_file_upload.phps16040644editdlrm
signed-mail.phps42030644editdlrm
smtp.phps18750644editdlrm
smtp_check.phps19390644editdlrm
smtp_no_auth.phps17430644editdlrm
ssl_options.phps20760644editdlrm
Edit: /home/techb158/exp.abdallabala.com/vendor/phpmailer/phpmailer/examples/smtp_check.phps (1939B)
do_debug = SMTP::DEBUG_CONNECTION; try { //Connect to an SMTP server if (!$smtp->connect('mail.example.com', 25)) { throw new Exception('Connect failed'); } //Say hello if (!$smtp->hello(gethostname())) { throw new Exception('EHLO failed: ' . $smtp->getError()['error']); } //Get the list of ESMTP services the server offers $e = $smtp->getServerExtList(); //If server can do TLS encryption, use it if (is_array($e) && array_key_exists('STARTTLS', $e)) { $tlsok = $smtp->startTLS(); if (!$tlsok) { throw new Exception('Failed to start encryption: ' . $smtp->getError()['error']); } //Repeat EHLO after STARTTLS if (!$smtp->hello(gethostname())) { throw new Exception('EHLO (2) failed: ' . $smtp->getError()['error']); } //Get new capabilities list, which will usually now include AUTH if it didn't before $e = $smtp->getServerExtList(); } //If server supports authentication, do it (even if no encryption) if (is_array($e) && array_key_exists('AUTH', $e)) { if ($smtp->authenticate('username', 'password')) { echo "Connected ok!"; } else { throw new Exception('Authentication failed: ' . $smtp->getError()['error']); } } } catch (Exception $e) { echo 'SMTP error: ' . $e->getMessage(), "\n"; } //Whatever happened, close the connection. $smtp->quit(true);